X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=jjb%2Fxci%2Fxci-cleanup.sh;h=51a863da2f020acd46964fdd2cc5dcf0a7bedca8;hb=2d45d3ab8789ab74be79c1179dd3b773a2490f9a;hp=45b4ec2737a3f108fc3f441fb36859d808a6254a;hpb=e5424a6cecf733f17f1cd16596938e3207d6c190;p=releng.git diff --git a/jjb/xci/xci-cleanup.sh b/jjb/xci/xci-cleanup.sh index 45b4ec273..51a863da2 100755 --- a/jjb/xci/xci-cleanup.sh +++ b/jjb/xci/xci-cleanup.sh @@ -14,11 +14,15 @@ # what you are doing. #---------------------------------------------------------------------- +# Need to cover macros with and without parameters +VM_NAME=$DISTRO +VM_NAME+=_xci_vm + # skip the deployment if the patch doesn't impact the deployment if [[ "$GERRIT_TOPIC" =~ 'skip-verify' ]]; then echo "Skipping the deployment!" exit 0 fi -sudo virsh destroy ${DISTRO}_xci_vm -sudo virsh undefine ${DISTRO}_xci_vm +sudo virsh destroy $VM_NAME || true +sudo virsh undefine $VM_NAME || true