From b8b200ad75c0b90d6248c82953b2318cfdd35cc5 Mon Sep 17 00:00:00 2001 From: Joachim Wiberg Date: Sun, 3 Apr 2022 12:13:42 +0200 Subject: [PATCH] doc: move state machine to inside its section Signed-off-by: Joachim Wiberg --- doc/service.md | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/doc/service.md b/doc/service.md index 714cfd36..1b9bd35f 100644 --- a/doc/service.md +++ b/doc/service.md @@ -15,12 +15,12 @@ Finit can *not* start and monitor a daemon that: * Forks to background and does *not* create a PID file -| | Forking | Creates PID File | Finit can create PID File | -|---|---------|------------------|---------------------------| -| ✔ | Yes | Yes | N/A | -| ✔ | No | Yes | N/A | -| ✔ | No | No | Yes | -| ✘ | Yes | No | No | +| | Forking | Creates PID File | Finit creates PID File | +|---|---------|------------------|------------------------| +| ✔ | Yes | Yes | No | +| ✔ | No | Yes | No | +| ✔ | No | No | Yes, optionally | +| ✘ | Yes | No | No | > **Note:** PID files is one mechanism used to assert conditions to > synchronize the start and stop of other, dependent, services. @@ -45,8 +45,6 @@ need it to synchronize start/stop of a dependent service. service pid:/run/servy.pid serv -n -p -P /run/servy.pid -- Foreground service w/ custom PID file -![The service state machine](svc-machine.png "The service state machine") - State Machine ------------- @@ -55,6 +53,8 @@ For `run`s and `task`s there is an additional end state called `DONE`, not shown in the diagram for brevity. Services start in the `HALTED` state. +![The service state machine](svc-machine.png "The service state machine") + The current state depends on the two following conditions: * `E`: Service enabled. In order for `E` to be satisfied, the service