From 4fc90bc2db6784aeabf0cfefdba4344f8c5671c5 Mon Sep 17 00:00:00 2001 From: bernat Date: Fri, 20 Mar 2020 18:13:08 +0100 Subject: [PATCH] Cleaning Jenkinsfile --- Jenkinsfile | 52 ++++++++++++++++++++++++++++++---------------------- 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 941f35dc4..b01a963cf 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -187,11 +187,22 @@ pipeline } } } - stage('Cleaning') - { - steps + } + post + { + always + { + deleteDir() + + node('master') { - deleteDir() + script + { + JOB_ID = "${env.BUILD_TAG}" + jenkinsLib = load("/home/jenkins/jenkins424.groovy") + + jenkinsLib.DeleteUbuntuBuildNode(JOB_ID) + } } } } @@ -296,27 +307,24 @@ pipeline } post { - always { deleteDir() } + always + { + deleteDir() + + node('master') + { + script + { + JOB_ID = "${env.BUILD_TAG}" + jenkinsLib = load("/home/jenkins/jenkins424.groovy") + + jenkinsLib.DeleteWindowsBuildNode(JOB_ID) + } + } + } } } } } } - post - { - always - { - node('master') - { - script - { - JOB_ID = "${env.BUILD_TAG}" - jenkinsLib = load("/home/jenkins/jenkins424.groovy") - - jenkinsLib.DeleteUbuntuBuildNode(JOB_ID) - jenkinsLib.DeleteWindowsBuildNode(JOB_ID) - } - } - } - } }