testing: Ignore hosts that are not running during shutdown
This allows properly terminating the environment if a host has crashed or was terminated manually for some reason.
This commit is contained in:
@@ -24,7 +24,12 @@ done
|
|||||||
for host in $STRONGSWANHOSTS
|
for host in $STRONGSWANHOSTS
|
||||||
do
|
do
|
||||||
log_action "Guest $host"
|
log_action "Guest $host"
|
||||||
execute "virsh shutdown $host"
|
|
||||||
|
if running_any $host; then
|
||||||
|
execute "virsh shutdown $host"
|
||||||
|
else
|
||||||
|
echo_warn "...not running"
|
||||||
|
fi
|
||||||
rm -f $VIRTIMGSTORE/$host.$IMGEXT
|
rm -f $VIRTIMGSTORE/$host.$IMGEXT
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user