-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (32 loc) · 1.33 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Release Go Binaries
on:
release:
types: [ created ]
jobs:
releases-matrix:
name: Release Go Binary
runs-on: ubuntu-latest
strategy:
matrix:
goos: [linux, darwin]
goarch: [amd64, arm64]
exclude:
- goarch: arm64
goos: linux
steps:
- uses: actions/checkout@v3
- name: Set APP_VERSION env
run: echo APP_VERSION=$(echo ${GITHUB_REF} | rev | cut -d'/' -f 1 | rev ) >> ${GITHUB_ENV}
- name: Set BUILD_TIME env
run: echo BUILD_TIME=$(date) >> ${GITHUB_ENV}
- name: Environment Printer
uses: managedkaos/[email protected]
- uses: wangyoucao577/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
goos: ${{ matrix.goos }}
goarch: ${{ matrix.goarch }}
asset_name: festivals-identity-server-${{ matrix.goos }}-${{ matrix.goarch }}
build_flags: -v
ldflags: -X 'github.com/Festivals-App/festivals-identity-server/server/status.ServerVersion=${{ env.APP_VERSION }}' -X 'github.com/Festivals-App/festivals-identity-server/server/status.BuildTime=${{ env.BUILD_TIME }}' -X 'github.com/Festivals-App/festivals-identity-server/server/status.GitRef=${{ github.ref }}'
extra_files: LICENSE README.md config_template.toml operation/service_template.service operation/update.sh