Skip to content

Commit

Permalink
ci: append REGISTRY to docker image name
Browse files Browse the repository at this point in the history
  • Loading branch information
SamyDjemai committed Nov 12, 2024
1 parent b06ae6a commit 36d4d08
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@ env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}

permissions:
contents: read
packages: write
attestations: write
id-token: write

jobs:
build:
runs-on: ubuntu-latest
Expand All @@ -25,12 +31,6 @@ jobs:
- linux/amd64
- linux/arm64

permissions:
contents: read
packages: write
attestations: write
id-token: write

steps:
- name: Prepare
run: |
Expand Down Expand Up @@ -64,7 +64,7 @@ jobs:
cache-from: type=gha,scope=${{ matrix.platform }}
cache-to: type=gha,scope=${{ matrix.platform }},mode=max
labels: ${{ steps.meta.outputs.labels }}
outputs: type=image,name=${{ env.IMAGE_NAME }},push-by-digest=true,name-canonical=true,push=true
outputs: type=image,name=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }},push-by-digest=true,name-canonical=true,push=true

- name: Export digest
run: |
Expand Down Expand Up @@ -112,8 +112,8 @@ jobs:
working-directory: /tmp/digests
run: |
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf '${{ env.IMAGE_NAME }}@sha256:%s ' *)
$(printf '${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}@sha256:%s ' *)
- name: Inspect image
run: |
docker buildx imagetools inspect ${{ env.IMAGE_NAME }}:${{ steps.meta.outputs.version }}
docker buildx imagetools inspect ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.meta.outputs.version }}

0 comments on commit 36d4d08

Please sign in to comment.