3 . $PWD/scripts/function.sh
5 echo "Stopping test environment"
7 NETWORKS="vnet1 vnet2 vnet3"
8 KNLTARGET=/var/run/kvm-swan-kernel
9 HOSTFSTARGET=/var/run/kvm-swan-hostfs
11 [ `id -u` -eq 0 ] || die "You must be root to run $0"
17 log_action "Network $net"
18 execute "virsh net-destroy $net"
21 for host in $STRONGSWANHOSTS
23 log_action "Guest $host"
24 execute "virsh destroy $host"
25 rm -f $VIRTIMGSTORE/$host.$IMGEXT
28 log_action "Removing kernel $KERNEL"
29 execute "rm $KNLTARGET"
31 log_action "Removing link to hostfs"
32 execute "rm $HOSTFSTARGET"