From e807c21d1cceeb378f8211da3b4d03ee4bccbdbe Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Fri, 12 Nov 2021 10:06:37 +0100 Subject: [slx-network] Skip copying dhcp scripts if openslx-udhcpc exists --- modules.d/slx-network/hooks/activate-bootif-dhcp.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/modules.d/slx-network/hooks/activate-bootif-dhcp.sh b/modules.d/slx-network/hooks/activate-bootif-dhcp.sh index 28e80f48..9a5f0b88 100644 --- a/modules.d/slx-network/hooks/activate-bootif-dhcp.sh +++ b/modules.d/slx-network/hooks/activate-bootif-dhcp.sh @@ -1,11 +1,13 @@ #!/bin/bash # # This script enables the udhcpc-based DHCP service for stage4, -# unless specifically disabled by 'SLX_STAGE4_DHCP="no"'. +# unless specifically disabled by 'SLX_STAGE4_DHCP="no"', +# or the OpenSLX udhcpc service/script exists in stage4. . /etc/openslx -if [ "$SLX_STAGE4_DHCP" != "no" ]; then +if [ "$SLX_STAGE4_DHCP" != "no" ] \ + && ! [ -e "${NEWROOT}/opt/openslx/scripts/udhcpc-openslx" ]; then mkdir -p "${NEWROOT}/opt/openslx/scripts" for script in setup-bootif-network udhcpc-trigger; do if [ -e "${NEWROOT}/opt/openslx/scripts/${script}" ]; then -- cgit v1.2.3-55-g7522