-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (37 loc) · 1.25 KB
/
go.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
37
38
39
40
41
# This workflow will build a golang project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
name: Go-build
on:
workflow_dispatch:
release:
types: [created]
jobs:
releases-matrix:
name: Release Go Binary
runs-on: ubuntu-latest
strategy:
matrix:
# build and publish in parallel: linux/386, linux/amd64, linux/arm64, windows/386, windows/amd64, darwin/amd64, darwin/arm64
goos: [linux]
goarch: ["386", amd64, arm64, mips, mipsle]
steps:
- uses: actions/checkout@v3
- name: Cloning repo
run: |
rm -rf ./{,.[!.],..?}*
git clone https://github.com/cloudflare/cloudflared .
- uses: wangyoucao577/go-release-action@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
goos: ${{ matrix.goos }}
goarch: ${{ matrix.goarch }}
goamd64: v1
release_tag: latest
build_flags: "-a"
project_path: "./cmd/cloudflared"
binary_name: "cloudflared"
ldflags: "-w -s"
executable_compression: "upx --ultra-brute"
overwrite: true
release_name: "Release"
asset_name: cloudflared-latest-${{ matrix.goos }}-${{ matrix.goarch }}