diff options
Diffstat (limited to 'core')
-rwxr-xr-x | core/modules/run-virt/data/opt/openslx/scripts/runvirt-start_dhcpd | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/modules/run-virt/data/opt/openslx/scripts/runvirt-start_dhcpd b/core/modules/run-virt/data/opt/openslx/scripts/runvirt-start_dhcpd index 99320dd6..42091584 100755 --- a/core/modules/run-virt/data/opt/openslx/scripts/runvirt-start_dhcpd +++ b/core/modules/run-virt/data/opt/openslx/scripts/runvirt-start_dhcpd @@ -14,8 +14,8 @@ FALLBACK_DOMAIN="virtual.localnet" getips () { [ -z "$1" ] && return [ "$1" = "$FALLBACK_DOMAIN" ] && return - # Output in one line by using echo without quotes - echo $(busybox timeout 2 nslookup "$1" 2>/dev/null | grep -A 4 '^Name:' | grep -E '^Address\s*[0-9]*: ' | awk -F': ' '{print $2}' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+' | awk '{print $1}') + mapfile -t out < <( busybox timeout 2 nslookup "$1" 2>/dev/null | grep -A 4 '^Name:' | grep -E '^Address\s*[0-9]*: ' | awk -F': ' '{print $2}' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+' ) + printf "%s" "${out[*]}" } # read the DNS configuration and configure the udhcpd |