Ubuntu 15.04 gogs (git repository) binary installation

Source: Internet
Author: User

1. Download the wind is coming. Fox

Http://gogs.io/docs/installation/install_from_binary.html

Download the latest version of

wget Https://github.com/gogits/gogs/releases/download/v0.6.1/linux_amd64.zip
2. Create a new user

AddUser git
Enter the password yourself
3. Unzip
Unzip Linux_amd64.zip
Mobile storage location, stored in/www/directory

MV Gogs/www/gogs
4. Database

The database must have been installed first, this is MySQL.

Execute the import of the following file (or the SQL statement that you manually execute the file):

/www/gogs/scripts/mysql.sql
5. Execution of commands
/www/gogs/gogs Web

If you need to customize the port

/www/gogs/gogs Web-port 3001
3001: Indicates access port 6. Open Browser settings

Here the server address is:

Note: To set some parameters for the first time

http://192.168.1.11:3001
7. Set the relevant parameters in the page

To set some parameters, such as Administrator, database, warehouse address, warehouse user,

Slightly.

localhost to 192.168.1.11

8. Set Boot to boot 8.1 modify boot file

/www/gogs/scripts/init/debian/gogs
put:

Workingdir=/home/git/gogs
Modified to:

Workingdir=/www/gogs/gogs
Put

Usage: $SCRIPTNAME
Modified to:

Usage: $WORKINGDIR
8.2 Setting up the service

Vim/lib/systemd/system/gogs.service
The file contents are as follows

[Unit] Description=gogsafter=network.target[service]type=forkingexecstart=/www/gogs/scripts/init/debian/gogs Startexecreload=/www/gogs/scripts/init/debian/gogs Restartexecstop=/www/gogs/scripts/init/debian/gogs  Stopprivatetmp=true[install]wantedby=multi-user.target
8.3 Setup Commands

#启用开机启动systemctl enable gogs.service# to start (if not, start with the following command) systemctl start Gogs.service



Ubuntu 15.04 gogs (git repository) binary installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.