[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[shepherd] 01/02: doc: Update user services example for `services alread
From: |
Ludovic Courtès |
Subject: |
[shepherd] 01/02: doc: Update user services example for `services already running'. |
Date: |
Sat, 4 Mar 2023 17:06:51 -0500 (EST) |
civodul pushed a commit to branch master
in repository shepherd.
commit b4a8dd66bf071377f47d66db3c553c73efe71965
Author: Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
AuthorDate: Sun Jan 29 12:05:32 2023 +0100
doc: Update user services example for `services already running'.
The previously suggested example now gives
Services already running, so not daemonizing.
which is fixed by daemonizing right away.
This is a follow-up to commit
3197c1c161d10b7f76771a2943f20fdafc5cc14a
service: 'daemonize' action does nothing when services are already
running.
* doc/shepherd.texi (Managing User Services): Daemonize before starting
services.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
doc/shepherd.texi | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/doc/shepherd.texi b/doc/shepherd.texi
index 2224ee0..3115789 100644
--- a/doc/shepherd.texi
+++ b/doc/shepherd.texi
@@ -13,7 +13,7 @@ Copyright @copyright{} @value{OLD-YEARS} Wolfgang J@"ahrling@*
Copyright @copyright{} @value{NEW-YEARS} Ludovic Courtès@*
Copyright @copyright{} 2020 Brice Waegeneire@*
Copyright @copyright{} 2020 Oleg Pykhalov
-Copyright @copyright{} 2020 Jan (janneke) Nieuwenhuizen@*
+Copyright @copyright{} 2020, 2023 Jan (janneke) Nieuwenhuizen@*
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -1321,6 +1321,9 @@ load individual service definitions from
(use-modules (shepherd service)
((ice-9 ftw) #:select (scandir)))
+;; Send shepherd into the background
+(action 'shepherd 'daemonize)
+
;; Load all the files in the directory 'init.d' with a suffix '.scm'.
(for-each
(lambda (file)
@@ -1329,8 +1332,6 @@ load individual service definitions from
(lambda (file)
(string-suffix? ".scm" file))))
-;; Send shepherd into the background
-(action 'shepherd 'daemonize)
@end lisp
Then, individual user services can be put in