Skip to content

Commit

Permalink
Sign releaser artifacts, not only container manifests
Browse files Browse the repository at this point in the history
The current goreleaser configuration leverages cosign to sign the
goreleaser container manifests using public sigstore infrastructure.
This is great!

This PR also signs the rest of the releaser artifacts (binaries, sbom
file, etc), so we can verify them using the aforementioned public
infrastructure. This is very useful for folks consuming the binaries
from the public GitHub releases.

Note that this assumes that the OIDC issuer is GitHub, and thus ties
this signature to be triggered a GitHub action.

Signed-off-by: Juan Antonio Osorio <juan.osoriorobles@eu.equinix.com>
  • Loading branch information
JAORMX committed Aug 30, 2022
1 parent db67f16 commit 50a62ed
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions goreleaser.yml
Expand Up @@ -235,6 +235,21 @@ docker_manifests:
- 'public.ecr.aws/aquasecurity/trivy:{{ .Version }}-s390x'
- 'public.ecr.aws/aquasecurity/trivy:{{ .Version }}-ppc64le'

signs:
- cmd: cosign
env:
- COSIGN_EXPERIMENTAL=1
signature: "${artifact}.sig"
certificate: "${artifact}.pem"
args:
- "sign-blob"
- "--oidc-issuer=https://token.actions.githubusercontent.com"
- "--output-certificate=${certificate}"
- "--output-signature=${signature}"
- "${artifact}"
artifacts: all
output: true

docker_signs:
- cmd: cosign
env:
Expand Down

0 comments on commit 50a62ed

Please sign in to comment.