1. Installation Configuration Git-daemon-run
Git-daemon-run is actually a script management tool used to start Git-daemon.
1.1 Create version root (end a)
If the/home/git/repositories directory already exists, you do not need to create it, otherwise:
sudo su gitcd/home/gitmkdir repositoriescd repositoriesgit init--bare manifest.git
1.2 Mounting Git-daemon-run (end a)
Apt-get Install Git-daemon-run
1.3 Configuring Git-daemon-run (A-end)
Vi/etc/sv/git-daemon/run
can see:
#!/bin/shexec 2>&1echo ' Git-daemon starting. ' EXEC Chpst-ugitdaemon "$ (git--exec-path)"/git-daemon--verbose--reuseaddr --base-path=/var/lib/var/lib/ Git
Modify the last line to:
--export-all--enable=receive-pack--base-path=/home/git/repositories/
Parameter description:
A)--export-all
With this option, you do not have to create a Git-daemon-export-ok file in your git repository. If you do not use this option, you will also need to create the file, which is
Touch Git-daemon-export-ok
b)--enable=receive-pack
1.4 Restarting Git deamon (end a)
sudo sv stop Git-daemonsudo SV start Git-daemon
Or:
sudo sv Restart Git-daemon
Ubuntu build Repo Server (ii): Configuration Git-daemon-run