diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2015-06-15 18:27:25 +0000 |
---|---|---|
committer | Laurent Bercot <ska-skaware@skarnet.org> | 2015-06-15 18:27:25 +0000 |
commit | 0a39023fd7229371dd3e505208a1c0e073414ac2 (patch) | |
tree | 9689d12f7b1ae6c0144bbcb446ab1f0ee5dedfff /doc/s6-supervise.html | |
parent | 9cc5f3b25284ddca50ad1a19a83b1d1153dc9f5d (diff) | |
download | s6-0a39023fd7229371dd3e505208a1c0e073414ac2.tar.xz |
- Readiness notification support in s6-supervise
- s6-notifywhenup deprecated
- Change abundantly documented
- rc for 2.1.4.0
Diffstat (limited to 'doc/s6-supervise.html')
-rw-r--r-- | doc/s6-supervise.html | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/doc/s6-supervise.html b/doc/s6-supervise.html index 0c40aa1..78db1fa 100644 --- a/doc/s6-supervise.html +++ b/doc/s6-supervise.html @@ -59,6 +59,47 @@ if <tt>./run</tt> exits too quickly. </li> sends a <tt>'x'</tt> event to <tt>./event</tt> before exiting 0. </li> </ul> +<h2> Options </h2> + +<p> + s6-supervise does not support options, because it is normally not run +manually via a command line; it is usually launched by its own +supervisor, <a href="s6-svscan.html">s6-svscan</a>. + However, the behaviour of an instance of s6-supervise can be tuned via +various configuration files in the service directory. These files, and +what they do, are listed on the +<a href="servicedir.html">service directory documentation page</a>. +</p> + +<h2> Readiness notification support </h2> + +<p> + If the <a href="servicedir.html">service directory</a> contains a valid +<tt>notification-fd</tt> file when the service is started, or restarted, +s6-supervise creates and listens to an additional pipe from the service +for <a href="notifywhenup.html">readiness notification</a>. When the +notification occurs, s6-supervise creates a <tt>./supervise/ready</tt> +file containing the absolute time when readiness occurred, then sends +a <tt>'U'</tt> event to <tt>./event</tt>. The <tt>./supervise/ready</tt> +file is deleted on service death. +</p> + +<p> + If the service is logged, i.e. if the service directory has a +<tt>log</tt> subdirectory that is also a service directory, and the +s6-supervise process has been launched by +that is also <a href="s6-svscan.html">s6-svscan</a>, then by default +the service's stdout goes into the logging pipe. If you set +<tt>notification-fd</tt> to 1, the logging pipe will be overwritten +by the notification pipe, which is probably not what you want. Instead, +if your daemon writes a notification message to its stdout, you should +set <tt>notification-fd</tt> to (for instance) 3, and redirect outputs +in your run script. For instance, to redirect stderr to the logger and +stdout to a <tt>notification-fd</tt> set to 3, you would start your +daemon as <tt>fdmove -c 2 1 fdmove 1 3 prog...</tt> (in execline), or +<tt>exec 2>&1 1>&3 3<&- prog...</tt> (in shell). +</p> + <h2> Signals </h2> <p> |