From: Yolanda Robla Date: Thu, 21 Nov 2019 11:31:54 +0000 (+0100) Subject: Add libvirt cleanup before starting the deploy X-Git-Tag: akraino_r2~6 X-Git-Url: https://gerrit.akraino.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F33%2F2033%2F1;p=kni%2Finstaller.git Add libvirt cleanup before starting the deploy In case some old clusters are there, it is possible that old bootstrap vms are still up. This script will clean all the previous contents of libvirt, ensuring a clean install. Signed-off-by: Yolanda Robla Change-Id: I95137fd798ab8c5f87f84280c1f7426326c46c86 --- diff --git a/ci/kni_deploy_baremetal.sh b/ci/kni_deploy_baremetal.sh index ed3d7ce..7c1438d 100755 --- a/ci/kni_deploy_baremetal.sh +++ b/ci/kni_deploy_baremetal.sh @@ -19,6 +19,10 @@ set -e -u -x -o pipefail SITE_NAME="testing.baremetal.edge-sites.net" MATCHBOX_ENDPOINT="http://172.22.0.1:8080" +wget https://raw.githubusercontent.com/openshift/installer/master/scripts/maintenance/virsh-cleanup.sh +chmod a+x ./virsh-cleanup.sh +sudo -E bash -c "yes Y | ./virsh-cleanup.sh" + rm -rf $HOME/.kni/$SITE_NAME pushd $HOME/go/src/gerrit.akraino.org/kni/installer ./knictl fetch_requirements file://${WORKSPACE}/$SITE_NAME