From a9e7c8c6afbd82ec4987cb328cc528d59e12f2e0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Zolt=C3=A1n=20Felleg?= Date: Wed, 5 Jan 2022 21:44:41 +0100 Subject: [PATCH] Updated all containers (the start order is set by the create script). --- scripts/create-container.sh | 13 +++++++++++++ sources/efg.pm/config | 4 ++-- sources/ens.pm/config | 4 ++-- sources/ifg.in/config | 4 ++-- sources/ins.in/config | 4 ++-- sources/ldap.in/config | 4 ++-- sources/ls.in/config | 4 ++-- sources/pns.in/config | 4 ++-- sources/pns.pm/config | 4 ++-- sources/svc.in/config | 4 ++-- sources/vpn.in/config | 4 ++-- sources/ws.pm/config | 4 ++-- sources/xfr.pm/config | 4 ++-- 13 files changed, 37 insertions(+), 24 deletions(-) diff --git a/scripts/create-container.sh b/scripts/create-container.sh index 720bb12..5281af4 100755 --- a/scripts/create-container.sh +++ b/scripts/create-container.sh @@ -70,6 +70,18 @@ CONTAINER_NAME="${CONTAINER_BASENAME}.$CONTAINER_OS" CONTAINER_PATH=$LXC_PATH/$CONTAINER_NAME CONTAINER_BUILD_PATH=$BUILD_PATH/$CONTAINER_NAME +CONTAINER_START_ORDER=$(grep -w $CONTAINER_BASENAME $SOURCES_PATH/start-order.txt \ + | awk '{print $2}') + +################################################################ +# exit if the container does not have a start order # +################################################################ +if [ -z "$CONTAINER_START_ORDER" ] +then + echo "The container does not have a start order." >&2 + exit 1 +fi + ################################################################ # exit if the container build directory already exists # ################################################################ @@ -133,6 +145,7 @@ mkdir --parents $CONTAINER_BUILD_PATH/rootfs echo "Creating container config and hooks." sed --expression="s|__CONTAINER_FILESYSTEMS_PATH__|$CONTAINER_FILESYSTEMS_PATH|" \ --expression="s|__CONTAINER_PATH__|$CONTAINER_PATH|" \ + --expression="s|__CONTAINER_START_ORDER__|$CONTAINER_START_ORDER|" \ <$CONTAINER_SOURCE_PATH/config \ >$CONTAINER_BUILD_PATH/config if [ -d $CONTAINER_SOURCE_PATH/hooks ] diff --git a/sources/efg.pm/config b/sources/efg.pm/config index e40602c..6850fab 100644 --- a/sources/efg.pm/config +++ b/sources/efg.pm/config @@ -30,5 +30,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 1 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/ens.pm/config b/sources/ens.pm/config index a9a178a..23f5aeb 100644 --- a/sources/ens.pm/config +++ b/sources/ens.pm/config @@ -17,5 +17,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 11 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/ifg.in/config b/sources/ifg.in/config index b35852a..c087d93 100644 --- a/sources/ifg.in/config +++ b/sources/ifg.in/config @@ -24,5 +24,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 2 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/ins.in/config b/sources/ins.in/config index 6722143..0d401a1 100644 --- a/sources/ins.in/config +++ b/sources/ins.in/config @@ -17,5 +17,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 22 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/ldap.in/config b/sources/ldap.in/config index 8c42308..b7cfe0c 100644 --- a/sources/ldap.in/config +++ b/sources/ldap.in/config @@ -17,5 +17,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 24 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/ls.in/config b/sources/ls.in/config index b4ee723..86dfcfd 100644 --- a/sources/ls.in/config +++ b/sources/ls.in/config @@ -18,5 +18,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 22 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/pns.in/config b/sources/pns.in/config index 5b49867..3785a57 100644 --- a/sources/pns.in/config +++ b/sources/pns.in/config @@ -17,5 +17,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 21 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/pns.pm/config b/sources/pns.pm/config index eb413d8..d4873bb 100644 --- a/sources/pns.pm/config +++ b/sources/pns.pm/config @@ -17,5 +17,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 12 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/svc.in/config b/sources/svc.in/config index d4c56cb..5b1e014 100644 --- a/sources/svc.in/config +++ b/sources/svc.in/config @@ -17,5 +17,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 23 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/vpn.in/config b/sources/vpn.in/config index 54dab81..367c338 100644 --- a/sources/vpn.in/config +++ b/sources/vpn.in/config @@ -18,5 +18,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 25 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/ws.pm/config b/sources/ws.pm/config index d53dd9a..e802166 100644 --- a/sources/ws.pm/config +++ b/sources/ws.pm/config @@ -21,5 +21,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 13 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 diff --git a/sources/xfr.pm/config b/sources/xfr.pm/config index bf2c2e0..c7cfb7e 100644 --- a/sources/xfr.pm/config +++ b/sources/xfr.pm/config @@ -18,5 +18,5 @@ lxc.cgroup2.devices.allow = a lxc.signal.halt = SIGRTMIN+4 lxc.start.auto = 1 -lxc.start.order = 14 -lxc.start.delay = 3 +lxc.start.order = __CONTAINER_START_ORDER__ +lxc.start.delay = 5 -- 2.54.0