diff options
author | Robin Houston <robin@lenny.robin> | 2011-06-29 23:20:50 +0100 |
---|---|---|
committer | Robin Houston <robin@lenny.robin> | 2011-06-29 23:20:50 +0100 |
commit | f1b6444b5c8a7af39f20411b0db63a4fea4d7819 (patch) | |
tree | e898f98c04057403f57b9721898fc8506f919334 | |
parent | fd27c8f2e0170fec22c78cf5e3dafa7e3fb3fa58 (diff) |
Hand the logfile opening over to the runner, rather than the start script.
-rw-r--r-- | config/alert-tracks-debian.ugly | 5 | ||||
-rwxr-xr-x | script/runner | 1 |
2 files changed, 3 insertions, 3 deletions
diff --git a/config/alert-tracks-debian.ugly b/config/alert-tracks-debian.ugly index 6a88ab67d..e4cc12b38 100644 --- a/config/alert-tracks-debian.ugly +++ b/config/alert-tracks-debian.ugly @@ -21,15 +21,14 @@ DUSER=!!(*= $user *)!! trap "" 1 -export PIDFILE +export PIDFILE LOGFILE quietly_start_daemon() { /sbin/start-stop-daemon --quiet --start --pidfile "$PIDFILE" --chuid "$DUSER" --startas "$DAEMON" -- $DAEMON_ARGS } start_daemon() { - /sbin/start-stop-daemon --start --pidfile "$PIDFILE" --chuid "$DUSER" --startas "$DAEMON" -- $DAEMON_ARGS \ - > "$LOGFILE" 2>&1 + /sbin/start-stop-daemon --start --pidfile "$PIDFILE" --chuid "$DUSER" --startas "$DAEMON" -- $DAEMON_ARGS } stop_daemon() { diff --git a/script/runner b/script/runner index 8cb4ec9d1..5a5254c47 100755 --- a/script/runner +++ b/script/runner @@ -15,6 +15,7 @@ Dir.chdir(alaveteli_dir) do if ENV.has_key? "LOGFILE" STDERR.reopen(STDOUT.reopen(ENV["LOGFILE"], "a")) STDOUT.sync=true + puts "Daemon starting at #{Time.new}" end # Load the runner in a subprocess |