summaryrefslogtreecommitdiff
path: root/man
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-06-24 16:13:56 +0200
committerLennart Poettering <lennart@poettering.net>2010-06-24 16:13:56 +0200
commitc61fbdfcb9bcd405c5a0a9b5f7050a58a871db6e (patch)
tree75b016ddc14d3114188b0f0d6a1b8e4467ed6b07 /man
parent58474090e965d5fcb9677bc746b5ecd079528de1 (diff)
man: extend systemd-notify man page a bit
Diffstat (limited to 'man')
-rw-r--r--man/systemd-notify.xml33
1 files changed, 33 insertions, 0 deletions
diff --git a/man/systemd-notify.xml b/man/systemd-notify.xml
index 46f3f1afa..5286418cc 100644
--- a/man/systemd-notify.xml
+++ b/man/systemd-notify.xml
@@ -73,6 +73,11 @@
environment variables to send as part of the status
update.</para>
+ <para>Note that systemd will refuse reception of
+ status updates from this command unless
+ <varname>NotifyAccess=all</varname> is set for the
+ service unit this command is called from.</para>
+
</refsect1>
<refsect1>
@@ -154,6 +159,34 @@
</refsect1>
<refsect1>
+ <title>Example</title>
+
+ <example>
+ <title>Start-up Notification and Status Updates</title>
+
+ <para>A simple shell daemon that sends
+ start-up notifications after having set up its
+ communication channel. During runtime it sends
+ further status updates to the init
+ system:</para>
+
+ <programlisting>#!/bin/bash
+
+mkfifo /tmp/waldo
+systemd-notify --ready --status="Waiting for data..."
+
+while : ; do
+ read a &lt; /tmp/waldo
+ systemd-notify --status="Processing $a"
+
+ # Do something with $a ...
+
+ systemd-notify --status="Waiting for data..."
+done</programlisting>
+ </example>
+ </refsect1>
+
+ <refsect1>
<title>See Also</title>
<para>
<citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,