Skip to content
This repository has been archived by the owner on Jan 23, 2024. It is now read-only.

Commit

Permalink
docker/go/nethttp: go build -mod=mod
Browse files Browse the repository at this point in the history
Go 1.16 changed the "go build" command so that
it no longer automatically updates go.mod and
go.sum. Because we dynamically change the Go
agent version, we cannot set go.mod and go.sum
ahead of time. Pass in `-mod=mod` to reinstate
the old behaviour.
  • Loading branch information
axw committed Feb 17, 2021
1 parent 0bc492c commit 4f0579a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docker/go/nethttp/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ RUN git clone https://github.com/${GO_AGENT_REPO}.git /src/apm-agent-go
RUN (cd /src/apm-agent-go \
&& git fetch -q origin '+refs/pull/*:refs/remotes/origin/pr/*' \
&& git checkout ${GO_AGENT_BRANCH})
RUN CGO_ENABLED=0 go build
RUN CGO_ENABLED=0 go build -mod=mod

FROM alpine:latest
RUN apk add --update curl && rm -rf /var/cache/apk/*
Expand Down

0 comments on commit 4f0579a

Please sign in to comment.