ci: run in container #5
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "create release" | |
on: | |
push: | |
tags: | |
- 'v[0-9]+.[0-9]+.[0-9]+*' | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
container: | |
image: rockylinux:8 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup golang environment | |
uses: actions/setup-go@v5 | |
with: | |
go-version: "1.22" | |
- name: Install dependencies | |
run: go mod tidy | |
- name: Make sure app can build | |
run: make build | |
- name: Rename executable and calculate checksums | |
shell: bash | |
run: | | |
mv build/usr/bin/fishymetrics build/usr/bin/fishymetrics-linux-amd64 | |
for filename in build/usr/bin/*; do | |
[ -e "$filename" ] || continue; | |
sha256sum "$filename" >> checksum.txt; | |
done | |
- name: Release | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: | | |
build/usr/bin/* | |
checksum.txt |