vmware-tanzu / velero

Backup and migrate Kubernetes applications and their persistent volumes
https://velero.io
Apache License 2.0
8.76k stars 1.41k forks source link

Do not set minimum go toolchain version in release branches. #8397

Open kaovilai opened 2 days ago

kaovilai commented 2 days ago

Describe the problem/challenge you have

User requests that go.mod go and toolchain remain at patch 0. ie. go 1.22.0 because they do not have available in their downstream system a new enough go to compile and build 1.22.8.

The Go toolchain refuses to load a module or workspace that declares a minimum required Go version greater than the toolchain’s own version.

Describe the solution you'd like

The ask is that golang pinning like in https://github.com/vmware-tanzu/velero/commit/7cd92a5aac33c54b3e979775bd45e142615f8320 should be limited to outside of go.mod files.

We will still be able to fix CVEs by bumping toolchains used to newer go even with go.mod go 1.22.0

When GOTOOLCHAIN is set to local, the go command always runs the bundled Go toolchain.

If the $GOROOT/go.env file is missing or does not set a default, the go command assumes GOTOOLCHAIN=local.

Anything else you would like to add:

Being fixed in https://github.com/vmware-tanzu/velero/pull/8399

Slack: https://kubernetes.slack.com/archives/C6VCGP4MT/p1731439622318149?thread_ts=1730991728.424729&cid=C6VCGP4MT

Environment:

Vote on this issue!

This is an invitation to the Velero community to vote on issues, you can see the project's top voted issues listed here.
Use the "reaction smiley face" up to the right of this comment to vote.

blackpiglet commented 1 day ago

/assign @kaovilai