Make go binaries lighter
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
nemunaire 2022-02-19 15:50:05 +01:00
parent 21ef2f1372
commit f83821238b

View File

@ -15,12 +15,12 @@ steps:
- go vet -v ./checker
- go vet -v ./token-validator
- cd ./pkg/minichecker/cmd && go vet -v . && cd -
- cd ./pkg/login-app/cmd && go build -v . && cd -
- cd ./pkg/login-app/cmd && go build -v -ldflags="-s -w" . && cd -
- mkdir dist
- go build -v -o dist/checker ./checker
- go build -v -o dist/token-validator ./token-validator
- cd ./pkg/minichecker/cmd && go build -v -o ../../../dist/minichecker . && cd -
- cd ./pkg/login-app/cmd && go build -v -o ../../../dist/login-app . && cd -
- go build -v -ldflags="-s -w" -o dist/checker ./checker
- go build -v -ldflags="-s -w" -o dist/token-validator ./token-validator
- cd ./pkg/minichecker/cmd && go build -v -ldflags="-s -w" -o ../../../dist/minichecker . && cd -
- cd ./pkg/login-app/cmd && go build -v -ldflags="-s -w" -o ../../../dist/login-app . && cd -
trigger:
event:
@ -43,12 +43,12 @@ steps:
- go vet -v ./checker
- go vet -v ./token-validator
- cd ./pkg/minichecker/cmd && go vet -v . && cd -
- cd ./pkg/login-app/cmd && go build -v . && cd -
- cd ./pkg/login-app/cmd && go build -v -ldflags="-s -w" . && cd -
- mkdir dist
- go build -v -o dist/checker ./checker
- go build -v -o dist/token-validator ./token-validator
- cd ./pkg/minichecker/cmd && go build -v -o ../../../dist/minichecker . && cd -
- cd ./pkg/login-app/cmd && go build -v -o ../../../dist/login-app . && cd -
- go build -v -ldflags="-s -w" -o dist/checker ./checker
- go build -v -ldflags="-s -w" -o dist/token-validator ./token-validator
- cd ./pkg/minichecker/cmd && go build -v -ldflags="-s -w" -o ../../../dist/minichecker . && cd -
- cd ./pkg/login-app/cmd && go build -v -ldflags="-s -w" -o ../../../dist/login-app . && cd -
environment:
CGO_ENABLED: 0
GOARM: 5