s6-rc: fix so the service manager knows about readiness notifications again

This commit is contained in:
Colin 2024-03-26 13:34:38 +00:00
parent f59dd99470
commit 6c5b32aac2

View File

@ -270,6 +270,9 @@ let
mkdir $out/servicedirs/$svc mkdir $out/servicedirs/$svc
# don't auto-start the service when i add the supervisor # don't auto-start the service when i add the supervisor
touch $out/servicedirs/$svc/down touch $out/servicedirs/$svc/down
# s6-rc needs to know if the service supports readiness notifications,
# as this will determine if it waits for it when starting.
ln -s ${compiled}/servicedirs/$svc/notification-fd $out/servicedirs/$svc/notification-fd
done done
''; '';
in in
@ -297,9 +300,9 @@ in
local LIVE="$XDG_RUNTIME_DIR/s6/live" local LIVE="$XDG_RUNTIME_DIR/s6/live"
mkdir -p "$LIVE" # create parent dirs mkdir -p "$LIVE" # create parent dirs
rm -rf "$LIVE" # remove old state rm -rf "$LIVE"/* # remove old state
# the live dir needs to be read+write. initialize it via the template in ~/.config/s6: # the live dir needs to be read+write. initialize it via the template in ~/.config/s6:
cp --dereference -R "$HOME/.config/s6/live" "$LIVE" cp -R "$HOME/.config/s6/live"/* "$LIVE"
chmod -R 0700 "$LIVE" chmod -R 0700 "$LIVE"
# ensure the log dir, since that'll be needed by every service. # ensure the log dir, since that'll be needed by every service.