summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Bauer2020-10-28 16:42:09 +0100
committerJonathan Bauer2020-10-28 16:42:09 +0100
commitae74c225f94db7fbf8d9e2e400357feed04dc992 (patch)
tree85942a5e92f915c4754d89ce0d8f21aa9f0b916b
parent[slx-clock] remove unneeded fork (diff)
downloadsystemd-init-ae74c225f94db7fbf8d9e2e400357feed04dc992.tar.gz
systemd-init-ae74c225f94db7fbf8d9e2e400357feed04dc992.tar.xz
systemd-init-ae74c225f94db7fbf8d9e2e400357feed04dc992.zip
[slx-network] activate dhcp in stage4 by default
can be disabled by SLX_STAGE4_DHCP="no".
-rw-r--r--modules.d/slx-network/hooks/activate-bootif-dhcp.sh10
1 files changed, 6 insertions, 4 deletions
diff --git a/modules.d/slx-network/hooks/activate-bootif-dhcp.sh b/modules.d/slx-network/hooks/activate-bootif-dhcp.sh
index 7a7d797d..28e80f48 100644
--- a/modules.d/slx-network/hooks/activate-bootif-dhcp.sh
+++ b/modules.d/slx-network/hooks/activate-bootif-dhcp.sh
@@ -1,10 +1,11 @@
#!/bin/bash
#
-# This script configures the udhcpc-based DHCP service for
-# within stage4, unless specifically disabled by SLX_STAGE4_DHCP
+# This script enables the udhcpc-based DHCP service for stage4,
+# unless specifically disabled by 'SLX_STAGE4_DHCP="no"'.
. /etc/openslx
-if [ "$SLX_STAGE4_DHCP" = "yes" ]; then
+
+if [ "$SLX_STAGE4_DHCP" != "no" ]; then
mkdir -p "${NEWROOT}/opt/openslx/scripts"
for script in setup-bootif-network udhcpc-trigger; do
if [ -e "${NEWROOT}/opt/openslx/scripts/${script}" ]; then
@@ -24,4 +25,5 @@ if [ "$SLX_STAGE4_DHCP" = "yes" ]; then
# activate it for the bridge or the physical interface if not bridged
systemctl --quiet --root "$NEWROOT" enable "udhcpc-bootif"
fi
-true
+
+: