Skip to content

Commit ab3dc0d

Browse files
committed
Add new workflow
1 parent 7c34f4d commit ab3dc0d

File tree

2 files changed

+57
-2
lines changed

2 files changed

+57
-2
lines changed

.github/workflows/goreleaser.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: GoReleaser
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
permissions:
9+
contents: write
10+
packages: write
11+
12+
jobs:
13+
goreleaser:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
with:
19+
fetch-depth: 0
20+
21+
- name: Set up Go
22+
uses: actions/setup-go@v4
23+
with:
24+
go-version: '1.21'
25+
26+
- name: Set up Docker Buildx
27+
uses: docker/setup-buildx-action@v3
28+
29+
- name: Log in to GitHub Container Registry
30+
uses: docker/login-action@v3
31+
with:
32+
registry: ghcr.io
33+
username: ${{ github.actor }}
34+
password: ${{ secrets.GITHUB_TOKEN }}
35+
36+
- name: Install cosign
37+
uses: sigstore/cosign-installer@v3
38+
with:
39+
cosign-release: 'v2.2.0'
40+
41+
- name: Run GoReleaser
42+
uses: goreleaser/goreleaser-action@v5
43+
with:
44+
distribution: goreleaser
45+
version: latest
46+
args: release --clean
47+
env:
48+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
49+
AZURE_STORAGE_SAS_TOKEN: ${{ secrets.AZURE_STORAGE_SAS_TOKEN }}
50+
COSIGN_PRIVATE_KEY: ${{ secrets.COSIGN_PRIVATE_KEY }}
51+
COSIGN_PASSWORD: ${{ secrets.COSIGN_PASSWORD }}

.goreleaser.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,9 @@ dockers:
3636
blobs:
3737
# SAS token is passed via AZURE_STORAGE_SAS_TOKEN env var
3838
- provider: azblob
39-
bucket: "public/chainloop-platform-plugin?storage_account=chainloopplatform"
40-
directory: "/chainloop-platform-plugin"
39+
bucket: "public/chainloop-platform-plugin"
40+
directory: "chainloop-platform-plugin"
41+
extra_files:
42+
- glob: "./dist/*.tar.gz"
43+
- glob: "./dist/*.zip"
44+
- glob: "./dist/checksums.txt"

0 commit comments

Comments
 (0)