Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass effective kubelet version to controlplane ensurer #5256

Merged
merged 8 commits into from
Jan 14, 2022

Conversation

rfranzke
Copy link
Member

How to categorize this PR?

/area usability
/kind enhancement
/merge squash

What this PR does / why we need it:
After #4971 it is possible to have different Kubernetes versions for worker pools of Shoots. The provider extensions need to be able to properly deal with this situation. This PR tackles this part by

  • adapting the generic controlplane mutator to pass the effective kubelet version to the ensurer
  • documenting that provider extensions with CSI migration should implement validation to prevent different worker pool Kubernetes versions (compared to control plane version) when CSI migration version is not reached.

Which issue(s) this PR fixes:
Part of #3501 (comment)

Release note:

The `genericmutator.Ensurer` interface methods concerning kubelets were extended with an additional parameter for the effective kubelet versions. Implementors of this interface should make use of this parameter instead of parsing the version from the `Cluster` object.
In order to prepare provider extensions with CSI migration for supporting different Kubernetes versions per worker pools, the validation for `Shoot` resources should be extended according to [this document](https://github.com/gardener/gardener/tree/master/extensions/pkg/controller/csimigration/README.md#how-does-csi-migration-work-in-general).

@rfranzke rfranzke requested a review from a team as a code owner January 12, 2022 20:32
@gardener-robot gardener-robot added area/usability Usability related kind/enhancement Enhancement, improvement, extension merge/squash size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jan 12, 2022
@timebertt
Copy link
Member

/assign

Copy link
Member

@timebertt timebertt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One question, rest looks good.

timebertt
timebertt previously approved these changes Jan 13, 2022
Copy link
Member

@timebertt timebertt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@ialidzhikov
Copy link
Member

/assign

@ialidzhikov ialidzhikov added this to the v1.39 milestone Jan 14, 2022
@ialidzhikov
Copy link
Member

I cannot say I am very familiar with #3501 (comment) or with the changes from this PR. I left 1 comment from an overall look.
/unassign

Copy link
Member

@ialidzhikov ialidzhikov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@rfranzke rfranzke merged commit b822dfb into gardener:master Jan 14, 2022
@rfranzke rfranzke deleted the enh/k8s-version-per-pool branch January 14, 2022 15:03
krgostev pushed a commit to krgostev/gardener that referenced this pull request Apr 21, 2022
* Pass kubelet version in `kubelet.service` unit description

* Extend `Ensurer` interface methods with kubelet version

* Pass correct `kubeletVersion` to ensurer

By default, the `.spec.kubernetes.version` is used. However, when the kubelet's unit service description contains the version information then this version is passed.

* Adapt `provider-local` ensurer

* Add docs for extensions with CSI migration

Ref gardener#3501 (comment)

* gardenlets labels OSC with related worker pool name

* Generic mutator calculates effective kubelet version based on OSC pool name label and `Cluster` object

* Revert "Pass kubelet version in `kubelet.service` unit description"

This reverts commit 2caddc9.
krgostev pushed a commit to krgostev/gardener that referenced this pull request Jul 5, 2022
* Pass kubelet version in `kubelet.service` unit description

* Extend `Ensurer` interface methods with kubelet version

* Pass correct `kubeletVersion` to ensurer

By default, the `.spec.kubernetes.version` is used. However, when the kubelet's unit service description contains the version information then this version is passed.

* Adapt `provider-local` ensurer

* Add docs for extensions with CSI migration

Ref gardener#3501 (comment)

* gardenlets labels OSC with related worker pool name

* Generic mutator calculates effective kubelet version based on OSC pool name label and `Cluster` object

* Revert "Pass kubelet version in `kubelet.service` unit description"

This reverts commit 2caddc9.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/usability Usability related kind/enhancement Enhancement, improvement, extension size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants