Skip to content

Commit eb9b54f

Browse files
committed
up build for arm 2022-08-31
1 parent f57e783 commit eb9b54f

File tree

3 files changed

+53
-1
lines changed

3 files changed

+53
-1
lines changed

.github/build/linux.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ builds:
1616
- linux
1717
goarch:
1818
- amd64
19-
- arm64
2019
archives:
2120
- format: zip
2221

.github/build/linuxarm64.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
env:
2+
- GO111MODULE=on
3+
before:
4+
hooks:
5+
- go mod tidy
6+
project_name: scan4all
7+
builds:
8+
- id: scan4all-linux
9+
ldflags:
10+
- -s -w
11+
binary: scan4all
12+
env:
13+
- CGO_ENABLED=1
14+
main: main.go
15+
goos:
16+
- linux
17+
goarch:
18+
- arm64
19+
archives:
20+
- format: zip
21+
22+
checksum:
23+
name_template: "{{ .ProjectName }}-linux-checksums.txt"

.github/workflows/build.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,36 @@ jobs:
4949
env:
5050
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5151

52+
build-linux-arm64:
53+
runs-on: ubuntu-latest
54+
steps:
55+
- name: Code checkout
56+
uses: actions/checkout@v2
57+
with:
58+
fetch-depth: 0
59+
- uses: uraimo/run-on-arch-action@v2
60+
name: Run commands
61+
id: runcmd
62+
with:
63+
arch: armv6
64+
distro: ubuntu18.04
65+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
66+
- name: Set up Go
67+
uses: actions/setup-go@v2
68+
with:
69+
go-version: 1.19
70+
- name: Install Dependences
71+
run: sudo apt install -yy libpcap-dev upx
72+
73+
- name: Run GoReleaser
74+
uses: goreleaser/goreleaser-action@v2
75+
with:
76+
version: latest
77+
args: release -f .github/build/linuxarm64.yml --rm-dist
78+
env:
79+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
80+
81+
5282
build-windows:
5383
runs-on: windows-latest
5484
steps:

0 commit comments

Comments
 (0)