Skip to content

Commit

Permalink
Fail the multi-machine test if gateway is not reachable
Browse files Browse the repository at this point in the history
  • Loading branch information
rfan1 committed Jul 16, 2024
1 parent 05e643a commit d7b572f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/network_utils.pm
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ sub setup_static_network {
assert_script_run qq(echo -e "\\nSTARTMODE='auto'\\nBOOTPROTO='static'\\nIPADDR='$ip'\\nMTU='$mtu'">/etc/sysconfig/network/ifcfg-$iface);
assert_script_run 'rcnetwork restart';
assert_script_run 'ip addr';
assert_script_run "ping -c 1 $gw || journalctl -b --no-pager -o short-precise > /dev/$serialdev";
assert_script_run 'ping -c 1 $gw', fail_message => 'Gateway is not reachable, please check your network configuration and setups';
assert_script_run "ip -6 addr add $args{ipv6} dev $iface" if exists $args{ipv6};
}

Expand Down

0 comments on commit d7b572f

Please sign in to comment.