]> gitweb.fluxo.info Git - puppet-sshd.git/commitdiff
properly implement daemon
authorAntoine Beaupré <anarcat@koumbit.org>
Thu, 18 Jun 2015 20:21:49 +0000 (16:21 -0400)
committerAntoine Beaupré <anarcat@koumbit.org>
Thu, 18 Jun 2015 21:15:28 +0000 (17:15 -0400)
files/autossh.init.d

index fdb2c1682437ddae36ae3963aba3b1845a51d166..95670d372dc189bc8a19ad1631367a9083d20421 100644 (file)
@@ -46,9 +46,9 @@ do_start()
        #   0 if daemon has been started
        #   1 if daemon was already running
        #   2 if daemon could not be started
-        start-stop-daemon --start --quiet --user $USER --pidfile $PIDFILE --exec $DAEMON --test > /dev/null \
+        start-stop-daemon --start --quiet --background --user $USER --pidfile $PIDFILE --makepidfile --exec $DAEMON --test > /dev/null \
                || return 1
-       start-stop-daemon --start --quiet --user $USER --chuid $USER --pidfile $PIDFILE --exec $DAEMON -- \
+       start-stop-daemon --start --quiet --background --user $USER --chuid $USER --pidfile $PIDFILE --makepidfile --exec $DAEMON -- \
                $DAEMON_ARGS \
                || return 2
        # The above code will not work for interpreted scripts, use the next