cloudflared-mirror/.github/workflows/build.yml

39 lines
1.3 KiB
YAML
Raw Normal View History

# Build from source on FreeBSD.
name: build_freebsd
on: [push]
permissions: read-all
jobs:
build_freebsd:
runs-on: ubuntu-latest
env:
GOEXPERIMENT: "noboringcrypto"
2025-01-19 20:54:30 +00:00
# Looks like CGO is required for FreeBSD building
CGO_ENABLED: 1
steps:
- uses: actions/checkout@v4
- name: Building from source
id: build_freebsd
uses: vmactions/freebsd-vm@v1
with:
envs: 'GOEXPERIMENT CGO_ENABLED'
usesh: true
mem: 4096
# We're specifically building for OPNsense, which is most recently on FreeBSD 14.1
release: "14.1"
# Note that the test scripts require bash
prepare: |
pkg install -y sudo gmake bash git go golangci-lint curl wget fakeroot libffi rubygem-fpm
2025-01-19 19:00:09 +00:00
git config --global --add safe.directory /home/runner/work/cloudflared/cloudflared
run: |
2025-01-19 22:38:43 +00:00
gmake install-go
go mod download
go mod tidy
go install golang.org/x/tools/cmd/goimports@latest
2025-01-19 22:38:43 +00:00
gmake cloudflared cleanup-go
2025-01-20 20:30:47 +00:00
- name: Attach Build File to Job
uses: actions/upload-artifact@v4
with:
name: cloudflared-freebsd-amd64
path: cloudflared/cloudflared/cloudflared
retention-days: 90
overwrite: true