1
1
mirror of https://github.com/go-gitea/gitea synced 2024-12-25 10:04:27 +00:00

Merge pull request #1274 from Knorkebrot/master

fix debian init script
This commit is contained in:
无闻 2015-07-25 00:42:29 +08:00
commit fcd6b45192

View File

@ -49,10 +49,12 @@ do_start()
# 1 if daemon was already running # 1 if daemon was already running
# 2 if daemon could not be started # 2 if daemon could not be started
sh -c "start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile \\ sh -c "start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile \\
--exec $DAEMON -- $DAEMON_ARGS --test > /dev/null \\ --test --chdir $WORKINGDIR --chuid $USER \\
--exec $DAEMON -- $DAEMON_ARGS > /dev/null \\
|| return 1" || return 1"
sh -c "start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile \\ sh -c "start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile \\
--background --exec /bin/su -- - $USER -c \"cd \\\"$WORKINGDIR\\\" && $DAEMON -- $DAEMON_ARGS\" \\ --background --chdir $WORKINGDIR --chuid $USER \\
--exec $DAEMON -- $DAEMON_ARGS \\
|| return 2" || return 2"
} }