Skip to content

Commit c252b70

Browse files
committed
HACK: update release workflow for fork
1 parent 6eddd9a commit c252b70

File tree

2 files changed

+8
-31
lines changed

2 files changed

+8
-31
lines changed

.github/workflows/release.yml

Lines changed: 7 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -18,24 +18,16 @@ jobs:
1818
uses: actions/setup-go@v5
1919
with:
2020
go-version: '1.22.5'
21-
- name: Install Cosign
22-
uses: sigstore/cosign-installer@v3
23-
with:
24-
cosign-release: 'v2.2.4'
25-
- name: Store Cosign private key in a file
26-
run: 'echo "$COSIGN_KEY" > /tmp/cosign.key'
27-
shell: bash
28-
env:
29-
COSIGN_KEY: ${{secrets.COSIGN_KEY}}
3021
- name: Set up QEMU
3122
uses: docker/setup-qemu-action@v3
3223
- name: Set up Docker Buildx
3324
uses: docker/setup-buildx-action@v3
34-
- name: Login to DockerHub
25+
- name: Login to GitHub Container Registry
3526
uses: docker/login-action@v3
3627
with:
37-
username: ${{secrets.DOCKER_USERNAME}}
38-
password: ${{secrets.DOCKER_PASSWORD}}
28+
registry: ghcr.io
29+
username: ${{ github.repository_owner }}
30+
password: ${{ secrets.GITHUB_TOKEN }}
3931
- name: Generate SBOM
4032
uses: CycloneDX/gh-gomod-generate-sbom@v2
4133
with:
@@ -45,33 +37,18 @@ jobs:
4537
uses: docker/metadata-action@v5
4638
id: meta
4739
with:
48-
images: securego/gosec
40+
images: ghcr.io/${{ github.repository_owner }}/gosec
4941
flavor: |
5042
latest=true
5143
tags: |
5244
type=sha,format=long
5345
type=semver,pattern={{version}}
54-
- name: Release Binaries
55-
uses: goreleaser/goreleaser-action@v6
56-
with:
57-
version: latest
58-
args: release --clean
59-
env:
60-
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
61-
COSIGN_PASSWORD: ${{secrets.COSIGN_PASSWORD}}
6246
- name: Release Docker Image
6347
uses: docker/build-push-action@v6
6448
id: relimage
6549
with:
6650
platforms: linux/amd64,linux/arm/v7,linux/arm64,linux/ppc64le
67-
tags: ${{steps.meta.outputs.tags}}
68-
labels: ${{steps.meta.outputs.labels}}
51+
tags: ${{ steps.meta.outputs.tags }}
52+
labels: ${{ steps.meta.outputs.labels }}
6953
push: true
7054
build-args: GO_VERSION=1.22
71-
- name: Sign Docker Image
72-
run: cosign sign --yes --key /tmp/cosign.key ${DIGEST}
73-
env:
74-
TAGS: ${{steps.meta.outputs.tags}}
75-
COSIGN_PASSWORD: ${{secrets.COSIGN_PASSWORD}}
76-
COSIGN_PRIVATE_KEY: /tmp/cosign.key
77-
DIGEST: ${{steps.relimage.outputs.digest}}

action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ inputs:
1010

1111
runs:
1212
using: 'docker'
13-
image: 'docker://securego/gosec:2.20.0'
13+
image: 'docker://ghcr.io/zeta-chain/gosec:2.21.0-zeta'
1414
args:
1515
- ${{ inputs.args }}
1616

0 commit comments

Comments
 (0)