Skip to content

Commit 5669824

Browse files
Bot Updating Templated Files
1 parent 5f4ed7a commit 5669824

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

Jenkinsfile

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,9 @@ pipeline {
377377
// Build Docker container for push to LS Repo
378378
stage('Build-Single') {
379379
when {
380-
environment name: 'MULTIARCH', value: 'false'
380+
expression {
381+
env.MULTIARCH == 'false' || params.PACKAGE_CHECK == 'true'
382+
}
381383
environment name: 'EXIT_STATUS', value: ''
382384
}
383385
steps {
@@ -402,7 +404,10 @@ pipeline {
402404
// Build MultiArch Docker containers for push to LS Repo
403405
stage('Build-Multi') {
404406
when {
405-
environment name: 'MULTIARCH', value: 'true'
407+
allOf {
408+
environment name: 'MULTIARCH', value: 'true'
409+
expression { params.PACKAGE_CHECK == 'false' }
410+
}
406411
environment name: 'EXIT_STATUS', value: ''
407412
}
408413
parallel {
@@ -507,7 +512,7 @@ pipeline {
507512
sh '''#! /bin/bash
508513
set -e
509514
TEMPDIR=$(mktemp -d)
510-
if [ "${MULTIARCH}" == "true" ]; then
515+
if [ "${MULTIARCH}" == "true" ] && [ "${PACKAGE_CHECK}" == "false" ]; then
511516
LOCAL_CONTAINER=${IMAGE}:amd64-${META_TAG}
512517
else
513518
LOCAL_CONTAINER=${IMAGE}:${META_TAG}
@@ -568,7 +573,7 @@ pipeline {
568573
steps {
569574
sh '''#! /bin/bash
570575
echo "Packages were updated. Cleaning up the image and exiting."
571-
if [ "${MULTIARCH}" == "true" ]; then
576+
if [ "${MULTIARCH}" == "true" ] && [ "${PACKAGE_CHECK}" == "false" ]; then
572577
docker rmi ${IMAGE}:amd64-${META_TAG}
573578
else
574579
docker rmi ${IMAGE}:${META_TAG}
@@ -592,7 +597,7 @@ pipeline {
592597
steps {
593598
sh '''#! /bin/bash
594599
echo "There are no package updates. Cleaning up the image and exiting."
595-
if [ "${MULTIARCH}" == "true" ]; then
600+
if [ "${MULTIARCH}" == "true" ] && [ "${PACKAGE_CHECK}" == "false" ]; then
596601
docker rmi ${IMAGE}:amd64-${META_TAG}
597602
else
598603
docker rmi ${IMAGE}:${META_TAG}

0 commit comments

Comments
 (0)