From 62c122109c880b54d725f0fa526553e520dcb55e Mon Sep 17 00:00:00 2001 From: Michael Mraka Date: Mon, 22 Apr 2024 13:48:48 +0200 Subject: [PATCH] don't repush original image when building in security-compliance branch --- build_deploy.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build_deploy.sh b/build_deploy.sh index c265b795e..14e974fd9 100755 --- a/build_deploy.sh +++ b/build_deploy.sh @@ -37,12 +37,12 @@ export REGISTRY_AUTH_FILE="$AUTH_CONF_DIR/auth.json" podman login -u="$QUAY_USER" -p="$QUAY_TOKEN" quay.io podman login -u="$RH_REGISTRY_USER" -p="$RH_REGISTRY_TOKEN" registry.redhat.io podman build -f Dockerfile -t "${IMAGE}:${IMAGE_TAG}" . -podman push "${IMAGE}:${IMAGE_TAG}" if [[ "$GIT_BRANCH" == "origin/security-compliance" ]]; then podman tag "${IMAGE}:${IMAGE_TAG}" "${IMAGE}:${SECURITY_COMPLIANCE_TAG}" podman push "${IMAGE}:${SECURITY_COMPLIANCE_TAG}" else + podman push "${IMAGE}:${IMAGE_TAG}" podman tag "${IMAGE}:${IMAGE_TAG}" "${IMAGE}:latest" podman push "${IMAGE}:latest" if [[ -n "$IMAGE_VERSION" ]]; then