mirror of
https://github.com/troglobit/finit.git
synced 2026-11-10 16:31:21 +00:00
conditions.md: Remove ToC heading and rewrite introduction
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
1 parent
1ee1b9cec4
commit
4782b1dc54
1 file changed
+11
-8
+11
-8
@@ -4,9 +4,6 @@ Finit Conditions
|
|||||||

|

|
||||||
|
|
||||||
|
|
||||||
Table of Contents
|
|
||||||
-----------------
|
|
||||||
|
|
||||||
* [Introduction](#introduction)
|
* [Introduction](#introduction)
|
||||||
* [Triggering](#triggering)
|
* [Triggering](#triggering)
|
||||||
* [Built-in Conditions](#built-in--conditions)
|
* [Built-in Conditions](#built-in--conditions)
|
||||||
@@ -17,9 +14,13 @@ Table of Contents
|
|||||||
Introduction
|
Introduction
|
||||||
------------
|
------------
|
||||||
|
|
||||||
In addition to declaring allowed runlevels per service, it is also
|
Conditions are a new addition to Finit, introduced in v3, with the
|
||||||
possible to declare user-defined conditions as dependencies. Conditions
|
intention of providing a mechanism for common synchronization problems.
|
||||||
are specified within angle brackets (<>) in the service stanza.
|
For example: do not start this service until another process has
|
||||||
|
started, or until basic network access is available.
|
||||||
|
|
||||||
|
Conditions are similaar to declaring runlevels per service. They are
|
||||||
|
specified within angle brackets `<>` in a `service`/`task`/`run` stanza.
|
||||||
Multiple conditions may be specified separated by comma. Conditions are
|
Multiple conditions may be specified separated by comma. Conditions are
|
||||||
AND'ed during evaluation, i.e. all conditions must be satisfied in order
|
AND'ed during evaluation, i.e. all conditions must be satisfied in order
|
||||||
for a service to run.
|
for a service to run.
|
||||||
@@ -34,9 +35,11 @@ for a service to run.
|
|||||||
In this example the Network monitor daemon `netd` is not started until
|
In this example the Network monitor daemon `netd` is not started until
|
||||||
both the `svc/sbin/setupd` *and* `svc/sbin/zebra` conditions are
|
both the `svc/sbin/setupd` *and* `svc/sbin/zebra` conditions are
|
||||||
satisfied. An `svc` condition is satisfied by the corresponding
|
satisfied. An `svc` condition is satisfied by the corresponding
|
||||||
service's pidfile being created.
|
service's PID file being created.
|
||||||
|
|
||||||
Conditions also stops services when a condition no longer is asserted.
|
**NOTE:** Conditions also stop services when a condition is no longer
|
||||||
|
asserted. I.e., if the Zebra process above stops or restarts, netd
|
||||||
|
will also stop or restart.
|
||||||
|
|
||||||
|
|
||||||
Triggering
|
Triggering
|
||||||
|
|||||||
Reference in new issue
Block a user