Release automation and release build testing

We will be using this automation which is triggered on every new tag created in this repo for the upcoming helmfile 0.145.0 release.

Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com>
This commit is contained in:
Yusuke Kuoka 2022-06-10 02:07:30 +00:00
parent 4071f6aa99
commit 0948bbae1c
3 changed files with 73 additions and 0 deletions

29
.github/workflows/publish_binaries.yaml vendored Normal file
View File

@ -0,0 +1,29 @@
name: Publish Binaries
on:
push:
branches:
- "!*"
tags:
- "v*"
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v1
-
name: Set up Go
uses: actions/setup-go@v3
with:
go-version: ~1.18.1
-
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v1
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@ -0,0 +1,26 @@
name: Test Binary Builds
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v1
-
name: Set up Go
uses: actions/setup-go@v3
with:
go-version: ~1.18.1
-
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v1
with:
version: latest
args: release --rm-dist --snapshot

18
.goreleaser.yml Normal file
View File

@ -0,0 +1,18 @@
project_name: helmfile
builds:
- id: helmfile
main: .
env:
- CGO_ENABLED=0
ldflags:
- -s -w -X github.com/helmfile/helmfile/pkg/app/version.Version={{.Version}}
goos:
- darwin
- linux
- windows
goarch:
- amd64
- arm64
- "386"
changelog:
use: github-native