diff --git a/ssm b/ssm index 920b384..edc96bb 100755 --- a/ssm +++ b/ssm @@ -185,7 +185,8 @@ svc() { run_service_action 'cleanup' - rm -f "$svc_pidfile" "$service_pidfile" "$service_ready_flag" + rm -f "$svc_pidfile" "$service_pidfile" + service_oneshot || rm -f "$service_ready_flag" # Record the job exit code printf '%d' "$job_exit" > "$service_exit_file" @@ -612,8 +613,8 @@ qstatus() { nullexec status; } ## By default there is no ready check ready() { :; } -## Reset failes -reset-exit() { rm -f "$service_exit_file"; } +## Reset fails +reset-exit() { rm -f "$service_exit_file" "$service_ready_flag"; } # Main code ## Empty declarations