From: Markos Chandras Date: Fri, 14 Sep 2018 11:13:05 +0000 (+0100) Subject: jjb: xci: Do not wipe clean VM on failures X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?p=releng.git;a=commitdiff_plain;h=dc5dbd3e33a7a1a5feeb8e2837609095dd3666f0 jjb: xci: Do not wipe clean VM on failures If there is a CI failure, then we need the VM to be present so we can ssh to the slave and collect all the logs we can in order to debug the problem. However, in order to not leave stale VMs around, we should remove the VM if a job is scheduled again on the same node. As such, if we need to debug a build on the node, we need to disconnect the node from Jenkins so the VM is not wiped by a future job. Change-Id: I93e7d7402fe03c392b63b87e7d438191f6e7e9cc Signed-off-by: Markos Chandras --- diff --git a/jjb/xci/xci-verify-jobs.yaml b/jjb/xci/xci-verify-jobs.yaml index 020ec8bac..c5badc62f 100644 --- a/jjb/xci/xci-verify-jobs.yaml +++ b/jjb/xci/xci-verify-jobs.yaml @@ -161,6 +161,7 @@ description: 'Git URL to use on this Jenkins Slave' builders: + - 'xci-verify-clean-vm-macro' - 'xci-verify-set-scenario-macro' - inject: properties-file: "/tmp/$GERRIT_CHANGE_NUMBER/$DISTRO/scenario.properties" @@ -213,7 +214,6 @@ - role: BOTH build-on: - ABORTED - - FAILURE - NOT_BUILT - SUCCESS - UNSTABLE @@ -289,6 +289,12 @@ # ------------------------------- # builder macros # ------------------------------- +- builder: + name: 'xci-verify-clean-vm-macro' + builders: + - shell: + !include-raw: ./xci-cleanup.sh + - builder: name: 'xci-verify-set-scenario-macro' builders: