Unless the file ./no-setsid exists, supervise will run subordinate processes in a new process group.
If ./log is an executable file, supervise starts it before any of the above, and will restart it if it exits. Standard output from the main script will be redirected through a pipe to standard input of the log process. As a special case, if svc -dx is issued, the log will be stopped after the main service has stopped.
If the file s/down exists, supervise does not start the service immediately. You can use svc(8) to start the service and to give other commands to supervise.
If the file s/notify exists and is executable, supervise executes it when any script starts or stops. It is given four command-line arguments: The first is the name of the script being executed, one of start, run, stop, or log. The second is a status code, one of:
The third is the process ID of the newly created or just exited process. The fourth is the exit code or kill signal number, or 0 on start.
supervise maintains status information in a binary format inside the directory s/supervise, which must be writable to supervise. The status information can be read by svstat(8) .
supervise may exit immediately after startup if it cannot find the files it needs in s or if another copy of supervise is already running in s. Once supervise is successfully running, it will not exit unless it is killed or specifically asked to exit. You can use svok(8) to check whether supervise is successfully running and svup(8) to check if the supervised process is running. You can use svscan(8) to reliably start a collection of supervise processes.