diff --git a/prow.sh b/prow.sh index 7124b401..67d8dfb2 100755 --- a/prow.sh +++ b/prow.sh @@ -441,7 +441,8 @@ run_with_go () { else version=local fi - GOTOOLCHAIN=$version run "$@" + # Set GOMODCACHE to make sure Kubernetes does not need to download again. + GOTOOLCHAIN=$version GOMODCACHE="$(go env GOMODCACHE)" run "$@" } # Ensure that we have the desired version of kind.