Skip to content

Commit 51b1a8d

Browse files
committed
upstart scripts go in /etc/init/
Had some issues following this text when setting up my own git server. Upstart scripts in ubuntu in /etc/init/ http://upstart.ubuntu.com/cookbook/#job-configuration-file. Also the daemon should run with the --detached option or else the upstart job will spawn two processes, the git daemon and the shell process that started it.
1 parent 6c452e3 commit 51b1a8d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

book/04-git-server/sections/git-daemon.asc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ So, in the following file
2525

2626
[source,console]
2727
----
28-
/etc/event.d/local-git-daemon
28+
/etc/init/local-git-daemon.conf
2929
----
3030

3131
you put this script:
@@ -37,6 +37,7 @@ stop on shutdown
3737
exec /usr/bin/git daemon \
3838
--user=git --group=git \
3939
--reuseaddr \
40+
--detach \
4041
--base-path=/opt/git/ \
4142
/opt/git/
4243
respawn

0 commit comments

Comments
 (0)