mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
appliance: Wait for /etc/resolv.conf to be populated
Work around this issue with dhcpcd:
https://github.com/NetworkConfiguration/dhcpcd/issues/258
Fixes: commit 0e37e5feea
This commit is contained in:
@@ -121,6 +121,11 @@ if test "$guestfs_network" = 1; then
|
||||
dhclient $iface
|
||||
else
|
||||
dhcpcd $iface
|
||||
# https://github.com/NetworkConfiguration/dhcpcd/issues/258
|
||||
for i in `seq 0 10`; do
|
||||
if grep nameserver /etc/resolv.conf; then break; fi
|
||||
sleep 1
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user