Skip to content

Commit

Permalink
Set annotations on docker containers
Browse files Browse the repository at this point in the history
  • Loading branch information
cromefire committed Nov 25, 2023
1 parent 8b6aabf commit 656b90f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ jobs:
# https://github.com/docker/build-push-action
- name: Build and push Docker image in PR
id: build-and-push-pr
uses: docker/build-push-action@v5.0.0
uses: docker/build-push-action@v5.1.0
if: github.event_name == 'pull_request'
with:
context: .
Expand All @@ -117,14 +117,15 @@ jobs:
platforms: ${{ matrix.platform.docker }}
push: false
labels: ${{ steps.meta.outputs.labels }}
annotations: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max

# Build and push Docker image with Buildx (push if not on PR)
# https://github.com/docker/build-push-action
- name: Build and push Docker image outside Branch
id: build-and-push
uses: docker/build-push-action@v5.0.0
uses: docker/build-push-action@v5.1.0
if: github.event_name != 'pull_request'
with:
context: .
Expand All @@ -133,8 +134,7 @@ jobs:
platforms: ${{ matrix.platform.docker }}
push: true
labels: ${{ steps.meta.outputs.labels }}
# Wait for https://github.com/docker/build-push-action/issues/958
#annotations: ${{ steps.meta.outputs.labels }}
annotations: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
outputs: type=registry,name=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }},push-by-digest=true,name-canonical=true
Expand Down

0 comments on commit 656b90f

Please sign in to comment.