Skip to content

Commit

Permalink
Makefile: set GOTOOLCHAIN=local
Browse files Browse the repository at this point in the history
Set GOTOOLCHAIN=local for all make targets, and for renovate.

Have the "vendor" target (and by extension, "vendor-in-container", which
our validation in CI uses) clear any "toolchain" directive that might
have been added to go.mod through manual invocations of the compiler.

Signed-off-by: Nalin Dahyabhai <[email protected]>
  • Loading branch information
nalind committed Apr 22, 2024
1 parent 6fab028 commit ab791f3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/renovate.json5
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,7 @@
"**/tests/**"
],

"env": {
"GOTOOLCHAIN": "local"
}
}
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export GOPROXY=https://proxy.golang.org
export GOTOOLCHAIN=local

APPARMORTAG := $(shell hack/apparmor_tag.sh)
STORAGETAGS := exclude_graphdriver_devicemapper $(shell ./btrfs_tag.sh) $(shell ./btrfs_installed_tag.sh) $(shell ./hack/libsubid_tag.sh)
Expand Down Expand Up @@ -209,6 +210,7 @@ vendor-in-container:

.PHONY: vendor
vendor:
if test -n $(strip $(shell go env GOTOOLCHAIN)); then go mod edit -toolchain none ; fi
GO111MODULE=on $(GO) mod tidy
GO111MODULE=on $(GO) mod vendor
GO111MODULE=on $(GO) mod verify
Expand Down

0 comments on commit ab791f3

Please sign in to comment.