diff --git a/ssm b/ssm index 9653de7..5a44750 100755 --- a/ssm +++ b/ssm @@ -440,9 +440,6 @@ main() { # Die if there is no service config file [[ "$service_config" ]] || die 19 "Service not found: $1" - # Semi-hardcoded stuff - svc_pidfile="$rundir/$service_name.pid" - # We can handle other people's service configs, poorly if (( service_systemd )); then # I'm pretty sure we'll need this @@ -474,6 +471,9 @@ main() { (( service_respawn )) && die 21 "Refusing to respawn a service that manages itself." fi + # Semi-hardcoded stuff + svc_pidfile="$rundir/$service_name.pid" + # Service-level defaults default service_pidfile "$svc_pidfile" default service_logfile "$logdir/$service_name.log"