Skip to content

Commit

Permalink
don't repush original image when building in security-compliance branch
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelMraka committed Apr 22, 2024
1 parent d7694cc commit 62c1221
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion build_deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 62c1221

Please sign in to comment.