unconditionally restart trigger services on liminix-rebuild
We call s6-rc -u -p default to restart/start the base services on a rebuild, otherwise services that are only in the new configuration won't come up. However, this stops any service started by a trigger. So, workaround is to restart the trigger service and expect it to restart the services it manages if they're needed
This commit is contained in:
@@ -12,8 +12,11 @@
|
||||
new-hashes (hashes-from-file new)]
|
||||
(with-open [f (io.open "/tmp/restarts" :w)]
|
||||
(each [n h (pairs old-hashes)]
|
||||
(when (not (= h (. new-hashes n)))
|
||||
(f:write (.. n " restart\n")))))))
|
||||
(let [new (. new-hashes n)]
|
||||
(when (or (= h "force-restart")
|
||||
(= new "force-restart")
|
||||
(not (= h new)))
|
||||
(f:write (.. n " restart\n"))))))))
|
||||
|
||||
(fn exec [text command]
|
||||
(io.write (.. text ": "))
|
||||
|
Reference in New Issue
Block a user