From 5e73ff3357d30db737095b4f2ac88f2ae9af5aca Mon Sep 17 00:00:00 2001 From: Fatih Degirmenci Date: Wed, 29 Aug 2018 10:40:31 +0200 Subject: xci: Remove leftover VMs before proceeding with the deployment Change-Id: I12e1dc7d79ca74df1ba02e16e55e91f4f47a818c Signed-off-by: Fatih Degirmenci --- jjb/xci/xci-daily-jobs.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'jjb/xci') diff --git a/jjb/xci/xci-daily-jobs.yaml b/jjb/xci/xci-daily-jobs.yaml index 47bd83c8a..3627d1806 100644 --- a/jjb/xci/xci-daily-jobs.yaml +++ b/jjb/xci/xci-daily-jobs.yaml @@ -300,6 +300,15 @@ set -o errexit set -o pipefail + echo "Cleaning the leftovers from the earlier run" + echo "---------------------------------------------------------------------------------" + for vm in $(sudo virsh list --all --name | grep -v xci_vm); do + echo "Removing $vm" + sudo virsh destroy $vm > /dev/null 2>&1 || true + sudo virsh undefine $vm > /dev/null 2>&1 || true + done + echo "---------------------------------------------------------------------------------" + cd $WORKSPACE/xci && ./xci-deploy.sh echo "Prepare OPNFV VM for Functest" -- cgit 1.2.3-korg