Skip to content

Commit

Permalink
Update README.md to use attestations permission (#180)
Browse files Browse the repository at this point in the history
* Update README.md to use `attestations` permission

* Update e2e.yml

* Update ci.yml
  • Loading branch information
phillmv authored Apr 22, 2024
1 parent d66e134 commit 0f4889d
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 10 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ jobs:
name: GitHub Actions Test (Linux)
runs-on: ubuntu-latest
permissions:
contents: write
contents: read
attestations: write
id-token: write

steps:
Expand All @@ -64,7 +65,8 @@ jobs:
name: GitHub Actions Test (Windows)
runs-on: windows-latest
permissions:
contents: write
contents: read
attestations: write
id-token: write

steps:
Expand All @@ -81,7 +83,8 @@ jobs:
name: GitHub Actions Test (OCI)
runs-on: ubuntu-latest
permissions:
contents: write
contents: read
attestations: write
id-token: write
packages: write
env:
Expand Down Expand Up @@ -123,7 +126,8 @@ jobs:
name: GitHub Actions Test (Private)
runs-on: ubuntu-latest
permissions:
contents: write
contents: read
attestations: write
id-token: write

steps:
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ jobs:
name: Publish/Verify (Container Image)
runs-on: ubuntu-latest
permissions:
contents: write
attestations: write
contents: read
id-token: write
services:
registry:
Expand Down
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@ attest,
```yaml
permissions:
id-token: write
contents: write
attestations: write
contents: read # optional, usually required
```
The `id-token` permission gives the action the ability to mint the OIDC token
necessary to request a Sigstore signing certificate. The `contents`
necessary to request a Sigstore signing certificate. The `attestations`
permission is necessary to persist the attestation.

> **NOTE**: The set of required permissions will be refined in a future
Expand Down Expand Up @@ -167,7 +168,8 @@ jobs:
build:
permissions:
id-token: write
contents: write
attestations: write
contents: read
steps:
- name: Checkout
Expand Down Expand Up @@ -195,7 +197,8 @@ jobs:
build:
permissions:
id-token: write
contents: write
attestations: write
contents: read
steps:
- name: Checkout
Expand Down Expand Up @@ -247,7 +250,8 @@ jobs:
permissions:
id-token: write
packages: write
contents: write
attestations: write
contents: read
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
Expand Down

0 comments on commit 0f4889d

Please sign in to comment.