using CGO_ENABLED=0 again (-extldflags=-static didnt work for webapp).
This commit is contained in:
@@ -27,12 +27,13 @@ jobs:
|
||||
env:
|
||||
GOOS: linux
|
||||
GOARCH: amd64
|
||||
CGO_ENABLED=0
|
||||
run: |
|
||||
apt-get update && apt-get install -y file
|
||||
|
||||
cd $PROJECT_PATH
|
||||
go build -ldflags "-extldflags=-static -X main.goos=linux -X main.goarch=amd64" -o scrutiny-web-linux-amd64 -tags "static" webapp/backend/cmd/scrutiny/scrutiny.go
|
||||
go build -ldflags "-extldflags=-static -X main.goos=linux -X main.goarch=amd64" -o scrutiny-collector-metrics-linux-amd64 -tags "static" collector/cmd/collector-metrics/collector-metrics.go
|
||||
go build -ldflags "-X main.goos=linux -X main.goarch=amd64" -o scrutiny-web-linux-amd64 -tags "static" webapp/backend/cmd/scrutiny/scrutiny.go
|
||||
go build -ldflags "-X main.goos=linux -X main.goarch=amd64" -o scrutiny-collector-metrics-linux-amd64 -tags "static" collector/cmd/collector-metrics/collector-metrics.go
|
||||
|
||||
chmod +x scrutiny-web-linux-amd64
|
||||
chmod +x scrutiny-collector-metrics-linux-amd64
|
||||
@@ -43,6 +44,7 @@ jobs:
|
||||
env:
|
||||
GOOS: linux
|
||||
GOARCH: arm
|
||||
CGO_ENABLED=0
|
||||
run: |
|
||||
cd $PROJECT_PATH
|
||||
go build -ldflags "-X main.goos=linux -X main.goarch=arm" -o scrutiny-web-linux-arm -tags "static" webapp/backend/cmd/scrutiny/scrutiny.go
|
||||
@@ -55,6 +57,7 @@ jobs:
|
||||
env:
|
||||
GOOS: linux
|
||||
GOARCH: arm64
|
||||
CGO_ENABLED=0
|
||||
run: |
|
||||
cd $PROJECT_PATH
|
||||
go build -ldflags "-X main.goos=linux -X main.goarch=arm64" -o scrutiny-web-linux-arm64 -tags "static" webapp/backend/cmd/scrutiny/scrutiny.go
|
||||
@@ -76,6 +79,7 @@ jobs:
|
||||
env:
|
||||
GOOS: freebsd
|
||||
GOARCH: amd64
|
||||
CGO_ENABLED=0
|
||||
run: |
|
||||
cd $PROJECT_PATH
|
||||
go build -ldflags "-X main.goos=freebsd -X main.goarch=amd64" -o scrutiny-web-freebsd-amd64 -tags "static" webapp/backend/cmd/scrutiny/scrutiny.go
|
||||
|
||||
Reference in New Issue
Block a user