From 29d69e1a949b58dba98c449be1bab07955596cbe Mon Sep 17 00:00:00 2001 From: Kayou Date: Sun, 3 May 2020 23:44:49 +0200 Subject: [PATCH] Use getent instead of ping --- utils.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utils.sh b/utils.sh index dc96e25..46ac7ad 100755 --- a/utils.sh +++ b/utils.sh @@ -59,7 +59,7 @@ wait_container() # Wait for container to access the internet for j in $(seq 1 10); do - if lxc exec "$1" -- /bin/bash -c "ping -q -c 2 security.debian.org" >/dev/null 2>/dev/null; then + if lxc exec "$1" -- /bin/bash -c "getent hosts debian.org" >/dev/null 2>/dev/null; then break fi @@ -188,4 +188,4 @@ update_image() { lxc stop "$image_to_update-tmp" lxc delete "$image_to_update-tmp" -} \ No newline at end of file +}