Skip to content

Commit bd403d6

Browse files
authored
Merge pull request #9 from hercynium/goreleaser
Goreleaser
2 parents 7366db1 + 78010d6 commit bd403d6

File tree

2 files changed

+33
-12
lines changed

2 files changed

+33
-12
lines changed

.github/workflows/release.yaml

+15-2
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,23 @@ jobs:
2323
uses: actions/checkout@v4
2424
with:
2525
fetch-depth: 0
26-
- name: Build and Push Docker Images
27-
run: make docker-buildx GIT_TAG=${{ github.event.release.tag_name }}
26+
- name: Set up Go
27+
uses: actions/setup-go@v5
28+
with:
29+
go-version: stable
30+
- name: Run GoReleaser
31+
uses: goreleaser/goreleaser-action@v6
32+
with:
33+
distribution: goreleaser
34+
version: "~> v2"
35+
args: release --clean
2836
env:
2937
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
38+
KO_DOCKER_REPO: ghcr.io/${{ github.repository }}
39+
#- name: Build and Push Docker Images
40+
# run: make docker-buildx GIT_TAG=${{ github.event.release.tag_name }}
41+
# env:
42+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3043
- name: Build and Push OLM Bundle Image
3144
run: make bundle bundle-build bundle-push GIT_TAG=${{ github.event.release.tag_name }}
3245
env:

.goreleaser.yaml

+18-10
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,11 @@ before:
1010
# - go test ./...
1111

1212
builds:
13-
- env:
13+
- skip: true
14+
env:
1415
- CGO_ENABLED=0
1516
main: ./cmd
16-
binary: istio-fortsa
17+
binary: manager
1718
flags:
1819
- -trimpath
1920
ldflags:
@@ -22,10 +23,17 @@ builds:
2223
- linux
2324
goarch:
2425
- amd64
26+
- arm64
27+
28+
release:
29+
github:
30+
owner: hercynium
31+
name: istio-fortsa
2532

2633
kos:
2734
- base_image: gcr.io/distroless/static:nonroot
28-
repository: ghcr.io/{{ .Env.GITHUB_REPOSITORY }}
35+
repository: ghcr.io/hercynium/istio-fortsa
36+
main: ./cmd
2937
tags:
3038
- "{{ .Tag }}"
3139
- latest
@@ -55,14 +63,14 @@ kos:
5563
org.opencontainers.image.source: "{{ .Env.GITHUB_SERVER_URL }}/{{ .Env.GITHUB_REPOSITORY }}"
5664

5765

58-
release:
59-
skip_upload: true
60-
footer: |
61-
# Container images
66+
# release:
67+
# skip_upload: true
68+
# footer: |
69+
# # Container images
6270

63-
```
64-
ghcr.io/{{ .Env.GITHUB_REPOSITORY }}:{{ .Tag }}
65-
```
71+
# ```
72+
# ghcr.io/{{ .Env.GITHUB_REPOSITORY }}:{{ .Tag }}
73+
# ```
6674

6775
changelog:
6876
sort: asc

0 commit comments

Comments
 (0)