From 056ca4c6eab8b8d381358579fc074d9700d5d96c Mon Sep 17 00:00:00 2001 From: toby Date: Fri, 26 Oct 2018 20:45:18 +0200 Subject: [PATCH] fixing bug in udev rule writing for mgmt/gw interfaces --- debian/wit-network-config.postinst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/wit-network-config.postinst b/debian/wit-network-config.postinst index 3115f76..5c38dd1 100755 --- a/debian/wit-network-config.postinst +++ b/debian/wit-network-config.postinst @@ -124,9 +124,9 @@ case "$1" in ## blow we deal with real physical interfaces ## it is crucial that this `ifmac` block is above the rest, since if no mac is returned it will skip the loop and prevent the package install to fail - if [[ $ifname = mgmt1 ]] || [[ $if = mgmtgw1 ]] || [[ $if = ipmigw1 ]] ## we only support a single interface of these types and they are handled slightly differently in DNS, hence the workaround + if [[ $ifname = mgmt1 ]] || [[ $ifname = mgmtgw1 ]] || [[ $ifname = ipmigw1 ]] ## we only support a single interface of these types and they are handled slightly differently in DNS then - ifmac=$(dig_txt mac.${if}.${HOSTNAME}) || continue ## at this point skip the rest of the loop for interfaces that do not have a mac defined (those are basically not configured) + ifmac=$(dig_txt mac.${if}.${HOSTNAME}) || continue ## at this point skip the rest of the loop for interfaces that do not have a mac defined (those are basically not configured) else ifmac=$(dig_txt mac.${ifname}.${HOSTNAME}) || continue ## at this point skip the rest of the loop for interfaces that do not have a mac defined fi