Skip to content

Commit

Permalink
Windows docker build ensure cleanWorkspace cleans build tmp workspace
Browse files Browse the repository at this point in the history
Signed-off-by: Andrew Leonard <[email protected]>
  • Loading branch information
andrew-m-leonard committed Dec 17, 2024
1 parent 207bcc8 commit 4c1a1f8
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions pipelines/build/common/openjdk_build_pipeline.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -2199,6 +2199,17 @@ def buildScriptsAssemble(
}
cleanWorkspace = false
}
// For Windows docker build also clean alternative workspace
if ( buildConfig.TARGET_OS == 'windows' && buildConfig.DOCKER_IMAGE ) {
context.ws(workspace) {
try {
context.println "Windows docker build cleaning" + context.WORKSPACE
context.cleanWs notFailBuild: true
} catch (e) {
context.println "Failed to clean ${e}"
}
}
}
}
} catch (FlowInterruptedException e) {
throw new Exception("[ERROR] Controller clean workspace timeout (${buildTimeouts.CONTROLLER_CLEAN_TIMEOUT} HOURS) has been reached. Exiting...")
Expand Down

0 comments on commit 4c1a1f8

Please sign in to comment.