linode / linode-blockstorage-csi-driver

Container Storage Interface (CSI) Driver for Linode Block Storage
Apache License 2.0
64 stars 54 forks source link

ci: Use go.mod for selecting the Go version #168

Closed nesv closed 3 months ago

nesv commented 3 months ago

The "ci" workflow was previously using the "stable" and "oldstable" versions, which as of Go 1.22 introduces a slight change in how go.mod is formatted. This results in errors like

go: updates to go.mod needed; to update it:
    go mod tidy

in the workflow logs.

So instead of relying on mutable version labels like "stable" and "oldstable", this commit binds the version of Go used in CI to be what is specified in the repository's go.mod file.

This will allow us the ability to gradually update Go versions without needing to change the version in more than one place, and keep CI predictable.

General:

Pull Request Guidelines:

  1. [ ] Does your submission pass tests?
  2. [ ] Have you added tests?
  3. [x] Are you addressing a single feature in this PR?
  4. [x] Are your commits atomic, addressing one change per commit?
  5. [x] Are you following the conventions of the language?
  6. [x] Have you saved your large formatting changes for a different PR, so we can focus on your work?
  7. [x] Have you explained your rationale for why this feature is needed?
  8. [ ] Have you linked your PR to an open issue