aboutsummaryrefslogtreecommitdiff
path: root/shepherd/init.scm
blob: b458e599ca9ee33120c6b86ec32b455eb6877ec8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
(use-modules (shepherd service)
	     ((ice-9 ftw) #:select (scandir)))

;; Load all the files in the directory 'init.d' with a suffix '.scm'.
(for-each
  (lambda (file)
    (load (string-append "init.d/" file)))
  (scandir (string-append (dirname (current-filename)) "/init.d")
	   (lambda (file)
	     (string-suffix? ".scm" file))))

;; Send shepherd into the background
(action 'shepherd 'daemonize)