summaryrefslogtreecommitdiff
path: root/man/systemd.service.xml
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-07-27 11:51:11 +0200
committerLennart Poettering <lennart@poettering.net>2016-08-04 23:08:05 +0200
commit136dc4c4350dfcb1d61ceaac982d0d0a8e6e3863 (patch)
tree7a072beabe4f0076d91fdff5efeefff05d5b0a54 /man/systemd.service.xml
parentaf9d16e10a23899b821af19e54e339486a86bd82 (diff)
core: set $SERVICE_RESULT, $EXIT_CODE and $EXIT_STATUS in ExecStop=/ExecStopPost= commands
This should simplify monitoring tools for services, by passing the most basic information about service result/exit information via environment variables, thus making it unnecessary to retrieve them explicitly via the bus.
Diffstat (limited to 'man/systemd.service.xml')
-rw-r--r--man/systemd.service.xml8
1 files changed, 7 insertions, 1 deletions
diff --git a/man/systemd.service.xml b/man/systemd.service.xml
index 875d368fcf..e82edbe93e 100644
--- a/man/systemd.service.xml
+++ b/man/systemd.service.xml
@@ -429,7 +429,13 @@
service failed to start up correctly. Commands configured with this setting need to be able to operate even if
the service failed starting up half-way and left incompletely initialized data around. As the service's
processes have been terminated already when the commands specified with this setting are executed they should
- not attempt to communicate with them.</para></listitem>
+ not attempt to communicate with them.</para>
+
+ <para>Note that all commands that are configured with this setting are invoked with the result code of the
+ service, as well as the main process' exit code and status, set in the <varname>$SERVICE_RESULT</varname>,
+ <varname>$EXIT_CODE</varname> and <varname>$EXIT_STATUS</varname> environment variables, see
+ <citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry> for
+ details.</para></listitem>
</varlistentry>
<varlistentry>