Skip to content

Commit

Permalink
update cosign to keyless for regular docker build images
Browse files Browse the repository at this point in the history
  • Loading branch information
momentmaker committed Aug 19, 2024
1 parent ec2dd8a commit 5666829
Showing 1 changed file with 6 additions and 10 deletions.
16 changes: 6 additions & 10 deletions .github/actions/build-sign-publish-chainlink/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ runs:
name: Install cosign
uses: sigstore/cosign-installer@e1523de7571e31dbe865fd2e80c5c7c23ae71eb4 # v3.4.0
with:
cosign-release: "v1.6.0"
cosign-release: "v2.4.0"

- if: inputs.sign-images == 'true' && inputs.sign-method == 'keypair'
name: Sign the published root Docker image using keypair method
Expand All @@ -264,18 +264,16 @@ runs:
- if: inputs.sign-images == 'true' && inputs.sign-method == 'keyless'
name: Sign the published root Docker image using keyless method
shell: sh
env:
COSIGN_EXPERIMENTAL: 1
run: |
cosign sign "${{ env.root_image_name }}"
- if: inputs.verify-signature == 'true' && inputs.sign-method == 'keyless'
name: Verify the signature of the published root Docker image using keyless
shell: sh
env:
COSIGN_EXPERIMENTAL: 1
run: |
cosign verify "${{ env.root_image_name }}"
cosign verify "${{ env.root_image_name }}" \
--certificate-oidc-issuer https://token.actions.githubusercontent.com \
--certificate-identity "https://github.com/smartcontractkit/chainlink/.github/workflows/build-publish.yml@${{ github.ref }}"
- if: inputs.sign-images == 'true' && inputs.sign-method == 'keypair'
name: Sign the published non-root Docker image using keypair method
Expand All @@ -298,15 +296,13 @@ runs:
- if: inputs.sign-images == 'true' && inputs.sign-method == 'keyless'
name: Sign the published non-root Docker image using keyless method
shell: sh
env:
COSIGN_EXPERIMENTAL: 1
run: |
cosign sign "${{ env.nonroot_image_name }}"
- if: inputs.verify-signature == 'true' && inputs.sign-method == 'keyless'
name: Verify the signature of the published non-root Docker image using keyless
shell: sh
env:
COSIGN_EXPERIMENTAL: 1
run: |
cosign verify "${{ env.nonroot_image_name }}"
--certificate-oidc-issuer https://token.actions.githubusercontent.com \
--certificate-identity "https://github.com/smartcontractkit/chainlink/.github/workflows/build-publish.yml@${{ github.ref }}"

0 comments on commit 5666829

Please sign in to comment.