]>
git.ipfire.org Git - thirdparty/strongswan.git/blob - testing/stop-testing
3 DIR
=$
(dirname `readlink -f $0`)
5 .
$DIR/scripts
/function.sh
7 echo "Stopping test environment"
9 NETWORKS
="vnet1 vnet2 vnet3"
10 KNLTARGET
=/var
/run
/kvm-swan-kernel
11 HOSTFSTARGET
=/var
/run
/kvm-swan-hostfs
13 [ `id -u` -eq 0 ] || die
"You must be root to run $0"
19 log_action
"Network $net"
20 execute
"virsh net-destroy $net"
23 for host in $STRONGSWANHOSTS
25 log_action
"Guest $host"
26 execute
"virsh shutdown $host"
27 rm -f $VIRTIMGSTORE/$host.
$IMGEXT
30 log_action
"Removing kernel $KERNEL"
31 execute
"rm $KNLTARGET"
33 log_action
"Removing link to hostfs"
34 execute
"rm $HOSTFSTARGET"