From: Tobias Brunner Date: Tue, 6 Oct 2020 13:31:14 +0000 (+0200) Subject: testing: Ignore hosts that are not running during shutdown X-Git-Tag: 5.9.1rc1~4^2~16 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8f2b6d709448fa9be6538bbc70235b6900eb7c63;p=thirdparty%2Fstrongswan.git 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. --- diff --git a/testing/stop-testing b/testing/stop-testing index 8abf5f2239..6f705b8124 100755 --- a/testing/stop-testing +++ b/testing/stop-testing @@ -24,7 +24,12 @@ done for host in $STRONGSWANHOSTS do 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 done