Skip to content

Automate the provisioning of kubectl in security-scan based on the server's k8s version #310

@andypitcher

Description

@andypitcher

Context:
With Rancher Manager version support ranging from k8s 1.23 to 1.31, we can't rely on a uniq kubectl version when building and running the security-scan. Since one kubectl can only cover up to three k8s versions. See kubectl version skew policy.

To do:
Alternative 1:

Alternative 2:
Develop a Go script to do the following:

  • Connect to the server to check the version, then pick what kubectl version to choose.
  • Have a place (and naming) for multiple kubectl binaries.
  • Auto select the closest kubectl version to the api server (semver helps there).
  • Install kubectl version at runtime

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions