This commit is contained in:
2021-02-21 03:11:00 +01:00
parent d9fc33632c
commit 9ba4b4f4dd

View File

@@ -29,19 +29,18 @@ pipeline {
script{ script{
for(ImgRelease in ImgReleaseList){ for(ImgRelease in ImgReleaseList){
for(ImgVariant in ImgVariantList){ for(ImgVariant in ImgVariantList){
if (BuildDefault == 'true' && (ImgVariant).startsWith('Default-')) {
echo 'Building Default'
BuildThisLocal = true
} else if (BuildExtra == 'true' && (ImgVariant).startsWith('Extra-')) {
BuildThisLocal = true
echo 'Building Extra'
} else {
BuildThisLocal = false
echo 'not building'
}
if (BuildThisLocal == 'true') {
stage('Build image') { stage('Build image') {
when {
anyOf {
allOf {
expression { return (ImgVariant).startsWith('Default-') }
environment name: 'BuildDefault', value: 'true'
}
allOf {
expression { return (ImgVariant).startsWith('Extra-') }
environment name: 'BuildExtra', value: 'true'
}
}
}
steps { steps {
// Build script // Build script
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') { catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') {
@@ -59,6 +58,7 @@ pipeline {
} }
} }
} }
}
stage('Finish') { stage('Finish') {
steps { steps {
// Save generated files // Save generated files