sudo su
yum install -y git
다운로드할 폴더로 이동
cd /usr/local/bin
gitea repositoy 에서 원하는 버전 url get
wget https://github.com/go-gitea/gitea/releases/download/v1.21.0/gitea-1.21.0-linux-amd64
마지막 "git" 은 생성할 username
sudo useradd --shell /bin/bash --comment 'Git Admin' git
편한 이름으로 변경
mv gitea-* gitea
파일 권한 변경
chmod a+x ./gitea
버전 확인
gitea --version
mkdir -p /etc/gitea /var/lib/gitea/{custom,data,indexers,public,log}
chown -R git:git /var/lib/gitea/
chmod -R 770 /var/lib/gitea/
chown root:git /etc/gitea
chmod -R 770 /etc/gitea
파일 다운로드
wget https://raw.githubusercontent.com/go-gitea/gitea/master/contrib/systemd/gitea.service -P /etc/systemd/system/
systemctl daemon-reload
systemctl enable --now gitea
systemctl status gitea
설정 파일로 이동
yum install -y nginx
cd /etc/nginx
vi nginx.conf
i 누른 뒤
...
server {
...
include ...
location / {
proxy_pass http://localhost:3000;
}
입력 후 esc -> :wq
nginx 재시작
service nginx restart
인스턴스의 보안그룹에 인바운드 규칙 추가
http, 허용할 ip 규칙
public ip로 접속
db 설정(sqlite3 등)
설치 후 계정 생성