Commit b6c815e
feat(ci): attest build provenance (#101)
## Estate attestation rollout
Adds GitHub native build-provenance attestation to
`.github/workflows/ghcr-publish.yml`.
**Push mechanism:** nerdctl (`nerdctl build` + `nerdctl push` to
ghcr.io), image `ghcr.io/${{ github.repository }}`.
**How the digest is obtained:** `nerdctl push` has no `--digestfile`
flag, so immediately after the push the workflow reads the real
`sha256:...` digest back from the registry with `skopeo inspect --format
'{{.Digest}}'` (skopeo is pre-installed on `ubuntu-latest`),
authenticating with the same `GITHUB_TOKEN`. That digest is exported as
the `push` step output and fed to the attestation as `subject-digest` —
it is the exact digest the registry holds for the pushed tag, not a
guess.
**Changes:**
- Added `id-token: write` + `attestations: write` to the job
permissions.
- Captured the pushed digest via `skopeo inspect`.
- Added an `actions/attest-build-provenance@e8998f94…` (v2, pinned) step
with `push-to-registry: true`.
Verify with:
```
gh attest verify oci://ghcr.io/hyperpolymath/wokelang:<tag> --repo hyperpolymath/wokelang
```
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>1 parent 5e5d116 commit b6c815e
1 file changed
Lines changed: 20 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
18 | 20 | | |
19 | 21 | | |
20 | 22 | | |
| |||
40 | 42 | | |
41 | 43 | | |
42 | 44 | | |
| 45 | + | |
43 | 46 | | |
44 | 47 | | |
45 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
46 | 66 | | |
47 | 67 | | |
48 | 68 | | |
| |||
0 commit comments