stop clearing GOPATH in vendor scripts

if unset, go defaults to $HOME/go, and fails if $GOROOT is also set to the same directory

we were only doing this to be doubly sure that only modules were being used.
just depend on export GO111MODULE=on for that.
This commit is contained in:
Jordan Liggitt
2019-04-12 12:52:58 -04:00
parent ca55432599
commit fb0cea22dc
3 changed files with 2 additions and 6 deletions

View File

@@ -23,8 +23,6 @@ source "${KUBE_ROOT}/hack/lib/init.sh"
# Explicitly opt into go modules, even though we're inside a GOPATH directory
export GO111MODULE=on
# Explicitly clear GOPATH, to ensure nothing this script calls makes use of that path info
export GOPATH=
# Explicitly clear GOFLAGS, since GOFLAGS=-mod=vendor breaks dependency resolution while rebuilding vendor
export GOFLAGS=
# Detect problematic GOPROXY settings that prevent lookup of dependencies