Skip to content

Commit

Permalink
fix action
Browse files Browse the repository at this point in the history
  • Loading branch information
bwbohl authored Jun 20, 2024
1 parent 8b43572 commit f74c65e
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
if: github.event_name != 'pull_request'
uses: sigstore/cosign-installer@59acb6260d9c0ba8f4a2f9d9b48431a222b68e20
with:
cosign-release: 'v1.12.0'
cosign-release: 'v2.2.4'

- name: Set up QEMU
uses: docker/setup-qemu-action@v3
Expand Down Expand Up @@ -102,11 +102,13 @@ jobs:
# repository is public to avoid leaking data. If you would like to publish
# transparency data even for private images, pass --force to cosign below.
# https://github.com/sigstore/cosign
- name: Sign the published Docker image
if: ${{ github.event_name != 'pull_request' }}
- name: Sign the images with GitHub OIDC Token
env:
COSIGN_EXPERIMENTAL: "true"
# This step uses the identity token to provision an ephemeral certificate
# against the sigstore community Fulcio instance.
#run: cosign sign ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}@${{ steps.build-and-push.outputs.digest }}
run: echo "${{ steps.meta.outputs.tags }}" | xargs -I {} cosign sign {}@${{ steps.build-and-push.outputs.digest }}
DIGEST: ${{ steps.build-and-push.outputs.digest }}
TAGS: ${{ steps.meta.outputs.tags }}
run: |
images=""
for tag in ${TAGS}; do
images+="${tag}@${DIGEST} "
done
cosign sign --yes ${images}

0 comments on commit f74c65e

Please sign in to comment.