Skip to content

Commit

Permalink
feat: cosign binaries with goreleaser (#83)
Browse files Browse the repository at this point in the history
* Update release.yaml - install cosign before goreleaser

Signed-off-by: Mathieu Benoit <[email protected]>

* Update .goreleaser.yaml - cosign

Signed-off-by: Mathieu Benoit <[email protected]>

---------

Signed-off-by: Mathieu Benoit <[email protected]>
  • Loading branch information
mathieu-benoit authored Nov 21, 2024
1 parent 408c206 commit 2f64164
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ jobs:
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- name: Install Cosign
uses: sigstore/cosign-installer@v3
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v6
with:
Expand Down Expand Up @@ -48,8 +50,6 @@ jobs:
tags: |
ghcr.io/score-spec/score-k8s:${{ github.ref_name }}
ghcr.io/score-spec/score-k8s:latest
- name: Install Cosign
uses: sigstore/cosign-installer@v3
- name: Sign container image
run: |
cosign sign --yes ghcr.io/score-spec/score-k8s@${{ steps.build-push-container.outputs.digest }}
13 changes: 13 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,16 @@ brews:
commit_author:
name: rachfop
email: [email protected]
signs:
- cmd: cosign
signature: "${artifact}.sig"
certificate: "${artifact}.pem"
args:
- sign-blob
- '--oidc-provider=github-actions'
- '--output-certificate=${certificate}'
- '--output-signature=${signature}'
- '${artifact}'
- --yes
artifacts: all
output: true

0 comments on commit 2f64164

Please sign in to comment.