Skip to content

Commit b43d961

Browse files
committed
install: use ping -6 if no IPv4 configuration was done
This allows the test to get the IPv6 address from the host even if it starts with an IPv4 first (in which case the transient IPv4 would be use, rapidly causing issues). Signed-off-by: Yann Dirson <[email protected]>
1 parent 752177e commit b43d961

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

tests/install/conftest.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,11 @@ def remastered_iso(installer_iso, answerfile):
187187
PINGARGS="-c1"
188188
fi
189189
190+
# detect lack of ipv4 in installed host
191+
if grep -q "^MODE='none'\\$" /etc/firstboot.d/data/management.conf; then
192+
PINGARGS+=" -6"
193+
fi
194+
190195
ping $PINGARGS "$1"
191196
EOF
192197
chmod +x "$INSTALLIMG/usr/local/sbin/test-pingpxe.sh"

0 commit comments

Comments
 (0)