diff --git a/.drone.yml b/.drone.yml index 8099c12..9725aca 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,5 +1,6 @@ --- environment: + GOTOOLCHAIN: "local" CGO_ENABLED: "0" GOARCH: amd64 GOOS: linux @@ -40,6 +41,7 @@ steps: type: docker --- environment: + GOTOOLCHAIN: "local" CGO_ENABLED: "0" GOARCH: arm64 GOOS: linux @@ -80,6 +82,7 @@ steps: type: docker --- environment: + GOTOOLCHAIN: "local" CGO_ENABLED: "0" GOARCH: amd64 GOOS: linux @@ -120,6 +123,7 @@ steps: type: docker --- environment: + GOTOOLCHAIN: "local" CGO_ENABLED: "0" GOARCH: arm64 GOOS: linux diff --git a/Dockerfile b/Dockerfile index d6358f2..15afbea 100644 --- a/Dockerfile +++ b/Dockerfile @@ -7,6 +7,7 @@ FROM --platform=$BUILDPLATFORM ${from_builder} AS build ARG TARGETARCH ARG TARGETOS +ARG GOTOOLCHAIN=local RUN apk update && apk add --no-cache \ bash \ @@ -22,6 +23,7 @@ RUN ./build-compress.sh ENV CGO_ENABLED=0 ENV GOOS=${TARGETOS} ENV GOARCH=${TARGETARCH} +ENV GOTOOLCHAIN=${GOTOOLCHAIN} RUN go build -pgo=auto -v -trimpath -o "${GOBIN}/go-away" ./cmd/go-away RUN test -e "${GOBIN}/go-away"