Skip to content

Commit

Permalink
Add EXPECTED_TAG env
Browse files Browse the repository at this point in the history
  • Loading branch information
DOBEN committed Jun 25, 2024
1 parent f4a05c8 commit 31018b7
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/release-euro-demo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
env:
REGISTRY: docker.io
IMAGE_NAME: dapps-euroe-demo
EXPECTED_TAG: ${{ github.ref_name }}

jobs:
publish-docker-image:
Expand Down Expand Up @@ -36,7 +37,7 @@ jobs:
if docker manifest inspect ${FULL_IMAGE_TAG} > /dev/null; then
echo "::error ${FULL_IMAGE_TAG} already exists"
exit 1
elif [ ! "${{ github.ref_name }}" = "release/euroe-demo/${VERSION}" ]; then
elif [ ! "${EXPECTED_TAG}" = "release/euroe-demo/${VERSION}" ]; then
echo "::error Expected tag ${EXPECTED_TAG} does not match the version ${VERSION}."
exit 1
else
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/release-gallery-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
env:
REGISTRY: docker.io
IMAGE_NAME: dapp-gallery
EXPECTED_TAG: ${{ github.ref_name }}

jobs:
build-and-push-image:
Expand Down Expand Up @@ -39,7 +40,7 @@ jobs:
if docker manifest inspect ${FULL_IMAGE_TAG} > /dev/null; then
echo "::error ${FULL_IMAGE_TAG} already exists"
exit 1
elif [ ! "${{ github.ref_name }}" = "gallery/${VERSION}" ]; then
elif [ ! "${EXPECTED_TAG}" = "gallery/${VERSION}" ]; then
echo "::error Expected tag ${EXPECTED_TAG} does not match the version ${VERSION}."
exit 1
else
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/release-sign-message-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
env:
REGISTRY: docker.io
IMAGE_NAME: dapp-signmessage
EXPECTED_TAG: ${{ github.ref_name }}

jobs:
build-and-push-image:
Expand Down Expand Up @@ -39,7 +40,7 @@ jobs:
if docker manifest inspect ${FULL_IMAGE_TAG} > /dev/null; then
echo "::error ${FULL_IMAGE_TAG} already exists"
exit 1
elif [ ! "${{ github.ref_name }}" = "signmessage/${VERSION}" ]; then
elif [ ! "${EXPECTED_TAG}" = "signmessage/${VERSION}" ]; then
echo "::error Expected tag ${EXPECTED_TAG} does not match the version ${VERSION}."
exit 1
else
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/release-simple-age-verification-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
env:
REGISTRY: docker.io
IMAGE_NAME: dapp-simple-age-verification
EXPECTED_TAG: ${{ github.ref_name }}

jobs:
build-and-push-image:
Expand Down Expand Up @@ -39,7 +40,7 @@ jobs:
if docker manifest inspect ${FULL_IMAGE_TAG} > /dev/null; then
echo "::error ${FULL_IMAGE_TAG} already exists"
exit 1
elif [ ! "${{ github.ref_name }}" = "simple-age-verification/${VERSION}" ]; then
elif [ ! "${EXPECTED_TAG}" = "simple-age-verification/${VERSION}" ]; then
echo "::error Expected tag ${EXPECTED_TAG} does not match the version ${VERSION}."
exit 1
else
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/release-sponsored-txs-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ on:
env:
REGISTRY: docker.io
IMAGE_NAME: dapp-sponsored-txs
EXPECTED_TAG: ${{ github.ref_name }}

jobs:
build-and-push-image:
Expand Down Expand Up @@ -42,7 +43,7 @@ jobs:
if docker manifest inspect ${FULL_IMAGE_TAG} > /dev/null; then
echo "::error ${FULL_IMAGE_TAG} already exists"
exit 1
elif [ ! "${{ github.ref_name }}" = "sponsored-transactions/${VERSION}" ]; then
elif [ ! "${EXPECTED_TAG}" = "sponsored-transactions/${VERSION}" ]; then
echo "::error Expected tag ${EXPECTED_TAG} does not match the version ${VERSION}."
exit 1
else
Expand Down

0 comments on commit 31018b7

Please sign in to comment.