Skip to content

Commit f07c3f7

Browse files
committed
Generate build provenance attestation
1 parent aeebb0c commit f07c3f7

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

.github/workflows/publish.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ jobs:
1414
permissions:
1515
contents: read
1616
packages: write
17+
id-token: write
18+
attestations: write
1719

1820
steps:
1921
- uses: docker/setup-buildx-action@v3
@@ -23,6 +25,7 @@ jobs:
2325
username: ${{ github.actor }}
2426
password: ${{ github.token }}
2527
- uses: docker/build-push-action@v6
28+
id: push
2629
with:
2730
push: true
2831
platforms: |
@@ -33,3 +36,8 @@ jobs:
3336
outputs: type=image,oci-mediatypes=true,compression=zstd,compression-level=6,force-compression=true
3437
cache-from: type=gha
3538
cache-to: type=gha,mode=max
39+
- uses: actions/attest-build-provenance@v1
40+
with:
41+
subject-name: ghcr.io/${{ github.repository }}
42+
subject-digest: ${{ steps.push.outputs.digest }}
43+
push-to-registry: true

0 commit comments

Comments
 (0)