ubuntu16.04下gogs的搭建

2018-12-29  本文已影响0人  沧海99

gogs

创建git用户

sudo adduser git
cd /home
chown -R git.git git
chmod 700 git
cd /home/git
wget https://dl.gogs.io/0.12.0/gogs_0.12.0_linux_amd64.tar.gz
tar xf gogs_0.12.0_linux_amd64.tar.gz
cd /home/git/gogs/scripts
mysql -u 用户名 -p < mysql.sql
cp systemd/gogs.service /etc/systemd/system/
service nginx restart
systemctl start gogs.service
systemctl status gogs.service
lsof -i:3000
server {
        listen       80;
        server_name  域名;

        location / {
             proxy_pass http://IP:3000/;
             proxy_redirect default;
        }
    }
上一篇下一篇

猜你喜欢

热点阅读