Skip to content

Commit ac9d93d

Browse files
committed
feat: update permissions and fix subject-digest reference in build-and-push workflow
1 parent 0583b45 commit ac9d93d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

.github/workflows/build-and-push.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ jobs:
2222
permissions:
2323
contents: read
2424
packages: write
25+
attestations: write
26+
id-token: write
2527

2628
steps:
2729
- name: Checkout repository
@@ -49,6 +51,7 @@ jobs:
4951
type=schedule,pattern={{date 'YYYYMMDD'}}
5052
5153
- name: Build and push Docker image
54+
id: build
5255
uses: docker/build-push-action@v6
5356
with:
5457
context: .
@@ -63,5 +66,5 @@ jobs:
6366
uses: actions/attest-build-provenance@v3
6467
with:
6568
subject-name: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
66-
subject-digest: ${{ steps.meta.outputs.digest }}
69+
subject-digest: ${{ steps.build.outputs.digest }}
6770
push-to-registry: true

0 commit comments

Comments
 (0)