2019-08-07 05:53:35 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
2019-08-07 06:08:32 +00:00
|
|
|
echo "building docker images for ${GOOS}/${GOARCH} ..."
|
|
|
|
|
2019-08-07 05:53:35 +00:00
|
|
|
REPO="github.com/drone/drone"
|
|
|
|
|
|
|
|
# compile the server using the cgo
|
|
|
|
go build -ldflags "-extldflags \"-static\"" -o release/linux/${GOARCH}/drone-server ${REPO}/cmd/drone-server
|
|
|
|
|
|
|
|
# compile the runners with gcc disabled
|
|
|
|
export CGO_ENABLED=0
|
|
|
|
go build -o release/linux/${GOARCH}/drone-agent ${REPO}/cmd/drone-agent
|
|
|
|
go build -o release/linux/${GOARCH}/drone-controller ${REPO}/cmd/drone-controller
|