Skip to content

Commit

Permalink
github: only publish latest release images
Browse files Browse the repository at this point in the history
When building the container images for Packer (light and full), we
should only publish them in the version being built is a release, and
not a pre-release.

Changing this means that both light and full latest will always be only
a final release at any time.
  • Loading branch information
lbajolet-hashicorp committed Apr 9, 2024
1 parent 1c7930b commit cf3930e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -242,10 +242,10 @@ jobs:
target: release-light
arch: ${{ matrix.arch }}
tags: |
docker.io/hashicorp/${{ env.REPO_NAME }}:light
${{ steps.get-product-version.output.prerelease-product-version == "" && format("docker.io/hashicorp/{0}:light", env.REPO_NAME) }}
docker.io/hashicorp/${{ env.REPO_NAME }}:light-${{ env.version }}
docker.io/hashicorp/${{ env.REPO_NAME }}:${{ env.version }}
public.ecr.aws/hashicorp/${{ env.REPO_NAME }}:light
${{ steps.get-product-version.output.prerelease-product-version == "" && format("public.ecr.aws/hashicorp/{0}:light", env.REPO_NAME) }}
public.ecr.aws/hashicorp/${{ env.REPO_NAME }}:light-${{ env.version }}
public.ecr.aws/hashicorp/${{ env.REPO_NAME }}:${{ env.version }}
dev_tags: |
Expand All @@ -272,9 +272,9 @@ jobs:
target: release-full
arch: ${{ matrix.arch }}
tags: |
docker.io/hashicorp/${{ env.REPO_NAME }}:full
${{ steps.get-product-version.output.prerelease-product-version == "" && format("docker.io/hashicorp/{0}:full", env.REPO_NAME) }}
docker.io/hashicorp/${{ env.REPO_NAME }}:full-${{ env.version }}
public.ecr.aws/hashicorp/${{ env.REPO_NAME }}:full
${{ steps.get-product-version.output.prerelease-product-version == "" && format("public.ecr.aws/hashicorp/{0}:full", env.REPO_NAME) }}
public.ecr.aws/hashicorp/${{ env.REPO_NAME }}:full-${{ env.version }}
dev_tags: |
docker.io/hashicorppreview/${{ env.REPO_NAME }}:full-${{ env.version }}
Expand Down

0 comments on commit cf3930e

Please sign in to comment.