Skip to content

Commit

Permalink
Updated Jenkinsfile to clean workspace before and after each job
Browse files Browse the repository at this point in the history
  • Loading branch information
b1quint committed Mar 25, 2021
1 parent 65d0367 commit 0883891
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ pipeline {
TOX_ARGS = "astrodata geminidr gemini_instruments gempy recipe_system"
}
steps {
// Clean workspace before build
cleanWs()
echo "Running build #${env.BUILD_ID} on ${env.NODE_NAME}"
checkout scm
sh '.jenkins/scripts/setup_agent.sh'
Expand Down Expand Up @@ -197,9 +199,11 @@ pipeline {

}
post {
always {
deleteDir() /* clean up our workspace */
}
success {
sendNotifications 'SUCCESSFUL'
deleteDir() /* clean up our workspace */
}
failure {
sendNotifications 'FAILED'
Expand Down

0 comments on commit 0883891

Please sign in to comment.