feat(container): add image build validation steps
This commit is contained in:
13
vars/utils.groovy
Normal file
13
vars/utils.groovy
Normal file
@ -0,0 +1,13 @@
|
||||
import org.jenkinsci.plugins.pipeline.modeldefinition.Utils
|
||||
|
||||
void when(Boolean condition, body) {
|
||||
Map config = [:]
|
||||
body.resolveStrategy = Closure.OWNER_FIRST
|
||||
body.delegate = config
|
||||
|
||||
if (condition) {
|
||||
body()
|
||||
} else {
|
||||
Utils.markStageSkippedForConditional(STAGE_NAME)
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user