From 73880efc0465dfe5a8af5530b35588717ad7b26f Mon Sep 17 00:00:00 2001 From: Joe Lanford Date: Wed, 11 Dec 2024 21:41:14 -0500 Subject: [PATCH] gha: release: only push images for main branch Signed-off-by: Joe Lanford --- .github/workflows/release.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 9005c083..1dda8862 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -42,8 +42,8 @@ jobs: echo IMAGE_TAG="${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV echo GORELEASER_ARGS="--clean" >> $GITHUB_ENV echo ENABLE_RELEASE_PIPELINE=true >> $GITHUB_ENV - elif [[ $GITHUB_REF == refs/heads/* ]]; then - # Branch build. + elif [[ $GITHUB_REF == refs/heads/main ]]; then + # 'main' branch build. echo IMAGE_TAG="$(echo "${GITHUB_REF#refs/heads/}" | sed -r 's|/+|-|g')" >> $GITHUB_ENV echo GORELEASER_ARGS="--clean --skip=validate" >> $GITHUB_ENV elif [[ $GITHUB_REF == refs/pull/* ]]; then