wip: rewrite s6-rc-up-tree in an actual procgramming language

and write some tests for it, too
This commit is contained in:
Daniel Barlow
2024-07-03 23:35:33 +01:00
parent 143137cbc6
commit 2e8e05f31a
10 changed files with 178 additions and 2 deletions

View File

@@ -0,0 +1,14 @@
(local up-tree (require "s6-rc-up-tree"))
(os.remove (os.getenv "TEST_LOG"))
(let [[dir & services] arg]
(set arg services)
(up-tree.run dir))
;; the service starts
;; the service starts even if it is controlled
;; uncontrolled descendants start
;; controlled descendants don't start
;; descendants which depend on a _different_ controlled service, which is down, don't start
;; descendants which depend on a _different_ controlled service, which is up, do start