Gogs – Quick Installation on Ubuntu 14.04 (With init.d auto-start)

Gogs is like a private GitHub

Instead of the long method by installing it by source or the packager.io method

I figure out a very quick installation method on Ubuntu 14.04

No need to install Go, no compile, no supervisor, no reverse proxy

1. Install gogs from binary package, install it and it’s init.d auto-start control script

adduser --disabled-password git

wget https://dl.gogs.io/gogs_v0.7.33_linux_amd64.tar.gz
tar -xv -f gogs_v0.7.33_linux_amd64.tar.gz -C /home/git

ln -s /home/git/gogs/gogs /usr/sbin/gogs
ln -s /home/git/gogs/scripts/init/debian/gogs /etc/init.d/gogs
chmod +x /etc/init.d/gogs
update-rc.d gogs defaults

2. Install mysql-server if not installed

apt-get install mysql-server

3. Setup gogs by visiting http://{IP ADDRESS}:3000

4. Edit /home/git/gogs/custom/conf/app.ini if needed

5. Restart gogs

service gogs restart

 

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.