Move custom files to post-mods, add init-services anchor

This commit is contained in:
TheSpad 2022-07-22 14:57:59 +01:00
parent 3c7ccbd583
commit 4d28a9cdc6
No known key found for this signature in database
GPG key ID: 08F06191F4587860
6 changed files with 4 additions and 2 deletions

View file

@ -56,7 +56,7 @@ process_custom_services() {
cp "${SERVICE}" /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run cp "${SERVICE}" /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run
chmod +x /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run chmod +x /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run
echo "longrun" > /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/type echo "longrun" > /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/type
touch /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/dependencies.d/init-mods touch /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/dependencies.d/init-services
touch /etc/s6-overlay/s6-rc.d/init-mods-end/dependencies.d/custom-svc-"${NAME}" touch /etc/s6-overlay/s6-rc.d/init-mods-end/dependencies.d/custom-svc-"${NAME}"
echo "[custom-init] ${NAME}: copied" echo "[custom-init] ${NAME}: copied"
elif [ ! -f "${SERVICE}" ]; then elif [ ! -f "${SERVICE}" ]; then
@ -77,7 +77,7 @@ process_custom_services() {
cp "${SERVICE}" /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run cp "${SERVICE}" /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run
chmod +x /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run chmod +x /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/run
echo "longrun" > /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/type echo "longrun" > /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/type
touch /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/dependencies.d/init-mods touch /etc/s6-overlay/s6-rc.d/custom-svc-"${NAME}"/dependencies.d/init-services
touch /etc/s6-overlay/s6-rc.d/init-mods-end/dependencies.d/custom-svc-"${NAME}" touch /etc/s6-overlay/s6-rc.d/init-mods-end/dependencies.d/custom-svc-"${NAME}"
echo "[custom-init] ${NAME}: copied" echo "[custom-init] ${NAME}: copied"
elif [ ! -f "${SERVICE}" ]; then elif [ ! -f "${SERVICE}" ]; then

View file

@ -0,0 +1 @@
oneshot

View file

@ -0,0 +1 @@
# This file doesn't do anything, it just signals that services can start