ignore makefile.

pull/169/head
Jason Kulatunga 4 years ago
parent 0864b8000c
commit d252333ba9

@ -63,13 +63,15 @@ jobs:
env: env:
PROJECT_PATH: /go/src/github.com/analogj/scrutiny PROJECT_PATH: /go/src/github.com/analogj/scrutiny
GOPATH: /go GOPATH: /go
GOOS: freebsd
GOARCH: amd64
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Build Binaries - name: Build Binaries
uses: vmactions/freebsd-vm@v0.1.3 uses: vmactions/freebsd-vm@v0.1.3
with: with:
envs: 'PROJECT_PATH GOPATH' envs: 'PROJECT_PATH GOPATH GOOS GOARCH'
usesh: true usesh: true
#TODO: lock go version using https://www.jeremymorgan.com/tutorials/golang/how-to-install-go-freebsd/ #TODO: lock go version using https://www.jeremymorgan.com/tutorials/golang/how-to-install-go-freebsd/
prepare: pkg install -y curl go gmake prepare: pkg install -y curl go gmake
@ -77,13 +79,26 @@ jobs:
pwd pwd
ls -lah ls -lah
whoami whoami
env
freebsd-version freebsd-version
mkdir -p $(dirname "$PROJECT_PATH") mkdir -p $(dirname "$PROJECT_PATH")
cp -R $GITHUB_WORKSPACE $PROJECT_PATH cp -R $GITHUB_WORKSPACE $PROJECT_PATH
cd $PROJECT_PATH cd $PROJECT_PATH
make freebsd/amd64 mkdir -p /build
echo "building web binary (OS = ${GOOS}, ARCH = ${GOARCH})"
go build -ldflags "-extldflags=-static -X main.goos=${GOOS} -X main.goarch=${GOARCH}" -o /build/scrutiny-web-${GOOS}-${GOARCH} -tags "static netgo sqlite_omit_load_extension" webapp/backend/cmd/scrutiny/scrutiny.go
chmod +x "/build/scrutiny-web-${GOOS}-${GOARCH}"
file "/build/scrutiny-web-${GOOS}-${GOARCH}" || true
ldd "/build/scrutiny-web-${GOOS}-${GOARCH}" || true
echo "building collector binary (OS = ${GOOS}, ARCH = ${GOARCH})"
go build -ldflags "-extldflags=-static -X main.goos=${GOOS} -X main.goarch=${GOARCH}" -o /build/scrutiny-collector-metrics-${GOOS}-${GOARCH} -tags "static netgo" collector/cmd/collector-metrics/collector-metrics.go
chmod +x "/build/scrutiny-collector-metrics-${GOOS}-${GOARCH}"
file "/build/scrutiny-collector-metrics-${GOOS}-${GOARCH}" || true
ldd "/build/scrutiny-collector-metrics-${GOOS}-${GOARCH}" || true

Loading…
Cancel
Save