Returning unstable if stage fails
Some checks failed
LXC-ImageBuilder/Centos/pipeline/head This commit has test failures

This commit is contained in:
2021-02-21 22:31:51 +01:00
parent f9281d2c6c
commit 9a8b7feda5

2
Jenkinsfile vendored
View File

@@ -46,7 +46,7 @@ pipeline {
env.ImgRelease = ImgRelease env.ImgRelease = ImgRelease
env.ImgVariant = ImgVariant env.ImgVariant = ImgVariant
stage('Build image') { stage('Build image') {
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') { catchError(buildResult: 'UNSTABLE', stageResult: 'FAILURE') {
sh '''echo "$(date) Do Build for $ImgRelease - $ImgVariant" sh '''echo "$(date) Do Build for $ImgRelease - $ImgVariant"
ImgVariantName=${ImgVariant#Default-} && ImgVariantName=${ImgVariantName#Extra-} ImgVariantName=${ImgVariant#Default-} && ImgVariantName=${ImgVariantName#Extra-}
sudo $WORKSPACE/distrobuilder build-lxc Centos.yaml $WORKSPACE/REL/$ImgRelease-$ImgVariant/ -o image.release=$ImgRelease -o image.variant=$ImgVariantName sudo $WORKSPACE/distrobuilder build-lxc Centos.yaml $WORKSPACE/REL/$ImgRelease-$ImgVariant/ -o image.release=$ImgRelease -o image.variant=$ImgVariantName