rmmagent/.github/workflows/ci.yml

43 lines
949 B
YAML
Raw Normal View History

2022-06-18 01:59:24 +00:00
name: Run tests
on:
push:
branches:
- "*"
pull_request:
branches:
- "*"
jobs:
build:
runs-on: ubuntu-latest
name: Run tests
steps:
- uses: actions/checkout@v3
2023-04-07 20:00:28 +00:00
- uses: actions/setup-go@v4
2022-06-18 01:59:24 +00:00
with:
2023-08-07 05:39:36 +00:00
go-version: '1.20.7'
2022-06-18 01:59:24 +00:00
- name: Ensure linux agent compiles
run: |
ARCHS='amd64 386 arm64 arm'
for i in ${ARCHS}; do
env CGO_ENABLED=0 GOOS=linux GOARCH=${i} go build -ldflags "-s -w"
done
- name: Ensure windows agent compiles
run: |
ARCHS='amd64 386'
for i in ${ARCHS}; do
env CGO_ENABLED=0 GOOS=windows GOARCH=${i} go build -ldflags "-s -w"
done
- name: Ensure mac agent compiles
run: |
ARCHS='amd64 arm64'
for i in ${ARCHS}; do
env CGO_ENABLED=0 GOOS=darwin GOARCH=${i} go build -ldflags "-s -w"
done