Skip to content

Commit

Permalink
feat: add cosign with GitHub OIDC token
Browse files Browse the repository at this point in the history
Changed cosign action to sign with GitHub OIDC token instead
of tag.  This requires setting up a separate action step
for cosign that takes output of build-push step.

Signed-off-by: Arthur Savage <[email protected]>
  • Loading branch information
arthurus-rex committed Jul 26, 2024
1 parent ccb19cc commit 20cea0f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
cosign-release: 'v2.2.4'
- name: check-cosign-install
run: cosign version
- name: build-sign-push
- name: build-push
run: |
echo "Test message build-sign-push"
cat > ./Dockerfile <<EOF
Expand All @@ -29,5 +29,7 @@ jobs:
EOF
docker build -t quay.io/rh-ee-asavage/gha-image-test:latest .
docker push quay.io/rh-ee-asavage/gha-image-test:latest
cosign sign -y quay.io/rh-ee-asavage/gha-image-test:latest
echo "Success build-sign-push"
- name: sign-image
run: |
cosign sign -y quay.io/rh-ee-asavage/gha-image-test:latest@${{ steps.build-push.outputs.digest }}

0 comments on commit 20cea0f

Please sign in to comment.