From e3808bc0d8579af7151c1d2e21d89a479156c560 Mon Sep 17 00:00:00 2001 From: Brad Rydzewski Date: Thu, 29 Jun 2017 20:38:43 -0400 Subject: [PATCH] build agent with CGO disabled [ci skip] --- .drone.sh | 2 +- Dockerfile.agent | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.drone.sh b/.drone.sh index 4da03600..cafccdc7 100755 --- a/.drone.sh +++ b/.drone.sh @@ -23,4 +23,4 @@ git clone git@github.com:drone/drone-enterprise.git extras # build a static binary with the build number and extra features. go build -ldflags '-extldflags "-static" -X github.com/drone/drone/version.VersionDev=build.'${DRONE_BUILD_NUMBER} -o release/drone-server github.com/drone/drone/extras/cmd/drone-server -go build -ldflags '-extldflags "-static" -X github.com/drone/drone/version.VersionDev=build.'${DRONE_BUILD_NUMBER} -o release/drone-agent github.com/drone/drone/cmd/drone-agent +GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -ldflags '-X github.com/drone/drone/version.VersionDev=build.'${DRONE_BUILD_NUMBER} -o release/drone-agent github.com/drone/drone/cmd/drone-agent diff --git a/Dockerfile.agent b/Dockerfile.agent index 638d2e6d..240b42eb 100644 --- a/Dockerfile.agent +++ b/Dockerfile.agent @@ -1,7 +1,7 @@ # docker build --rm -t drone/drone . FROM centurylink/ca-certs - +ENV GODEBUG=netdns=go ADD release/drone-agent /bin/ ENTRYPOINT ["/bin/drone-agent"]