Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
kubeadm: improve the kubeconfig file validation phase #79165
What this PR does / why we need it:
In such a case the kubeconfig phase backend will panic,
Add nil checks for a couple of map operations in
Which issue(s) this PR fixes:
Special notes for your reviewer:
Does this PR introduce a user-facing change?:
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: neolit123
The full list of commands accepted by this bot can be found here.
The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing
When a kubeconfig file is read from disk it may lack the propper mapping between contexts and clusters. In such a case the kubeconfig phase backend will panic, without throwing a sensible error. Add nil checks for a couple of map operations in validateKubeConfig().