From 0350d7fe58b5a420b153e32c440c06bf9fcbb4ef Mon Sep 17 00:00:00 2001 From: thespad Date: Sun, 1 Dec 2024 23:06:06 +0000 Subject: [PATCH] Fix missing $ and match order to multi-push --- roles/generate-jenkins/templates/Jenkinsfile.j2 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/roles/generate-jenkins/templates/Jenkinsfile.j2 b/roles/generate-jenkins/templates/Jenkinsfile.j2 index 633e9d4a..e4106b61 100644 --- a/roles/generate-jenkins/templates/Jenkinsfile.j2 +++ b/roles/generate-jenkins/templates/Jenkinsfile.j2 @@ -525,7 +525,7 @@ pipeline { echo "Starting Stage 2.5 - Update init diagram" if ! grep -q 'init_diagram:' readme-vars.yml; then echo "Adding the key 'init_diagram' to readme-vars.yml" - sed -i '\\|^#.*changelog.*$|d' readme-vars.yml + sed -i '\\|^#.*changelog.*$|d' readme-vars.yml sed -i 's|^changelogs:|# init diagram\\ninit_diagram:\\n\\n# changelog\\nchangelogs:|' readme-vars.yml fi mkdir -p ${TEMPDIR}/d2 @@ -1130,7 +1130,7 @@ pipeline { retry_backoff(5,5) { sh '''#! /bin/bash set -e - for PUSHIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do + for PUSHIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do [[ ${PUSHIMAGE%%/*} =~ \\. ]] && PUSHIMAGEPLUS="${PUSHIMAGE}" || PUSHIMAGEPLUS="docker.io/${PUSHIMAGE}" IFS=',' read -ra CACHE <<< "$BUILDCACHE" for i in "${CACHE[@]}"; do @@ -1138,7 +1138,7 @@ pipeline { CACHEIMAGE=${i} fi done - docker buildx imagetools create --prefer-index=false -t ${PUSHIMAGE}:${META_TAG} -t ${PUSHIMAGE}:{{ release_tag }} -t {PUSHIMAGE}:${EXT_RELEASE_TAG} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} + docker buildx imagetools create --prefer-index=false -t ${PUSHIMAGE}:${META_TAG} -t ${PUSHIMAGE}:{{ release_tag }} -t ${PUSHIMAGE}:${EXT_RELEASE_TAG} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} if [ -n "${SEMVER}" ]; then docker buildx imagetools create --prefer-index=false -t ${PUSHIMAGE}:${SEMVER} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} fi