From bf10e852e1bd4a1bfcfb9468a5ad4398d653b077 Mon Sep 17 00:00:00 2001 From: Daniel Theophanes Date: Sun, 19 Apr 2015 17:14:10 -0700 Subject: [PATCH] sysv: support working directory. --- service_sysv_linux.go | 1 + 1 file changed, 1 insertion(+) diff --git a/service_sysv_linux.go b/service_sysv_linux.go index f0ea205..658ce2f 100644 --- a/service_sysv_linux.go +++ b/service_sysv_linux.go @@ -190,6 +190,7 @@ case "$1" in echo "Already started" else echo "Starting $name" + {{if .WorkingDirectory}}cd '{{.WorkingDirectory}}'{{end}} $cmd >> "$stdout_log" 2>> "$stderr_log" & echo $! > "$pid_file" if ! is_running; then