Skip to content

Introduce distributionVersion field for improved Kubernetes Distribution version handling #11816

Open
@rccrdpccl

Description

@rccrdpccl

What would you like to be added (User Story)?

As a user I would like to have a distributionVersion field to better handle versioning of the kubernetes distribution being installed

Detailed Description

Currently, the handling of Kubernetes versions in the version field is problematic when installing or upgrading a distribution of Kubernetes that utilizes its own version scheme and lifecycle. A distribution can include more software components than just Kubernetes, and/or a distinct support lifecycle that includes the release of fixes and other changes on its own timeline. Those characteristics can necessitate the use of an independent version scheme.
The version field, present in multiple resources: ControlPlane, MachineSpec, Cluster Topology, specifically represents the Kubernetes version. In order to control the cluster’s distribution version, we need to specify its value for the ControlPlane and MachineSet/MachineDeployment objects involved. This is problematic when a user wants to deploy a specific version of a kubernetes distribution, they cannot specify the version, but it should be calculated based on the related kubernetes version (which is not always possible in any case).

To address this, we propose introducing a new field, spec.distributionVersion in the following resources:

  • ControlPlane (ControlPlane.Spec.Version)
  • MachineSpec (Machine.Spec.Version /MachineSet.Spec.Template.Spec.Version/MachineDeploymen.Spec.Template.Spec.Version/MachinePool.Spec.Template.Spec.Version)
  • Topology (Cluster.Topology.Version)

The new field and the current spec.version would be mutually exclusive.

This would be an optional field for both the ControlPlane contract and MachineSpec. Its value would be the distribution version (e.g. for OpenShift it should be something like v4.17.0). No version semantics will be imposed on the field.

If distributionVersion is present, the status.version should be populated with the related kubernetes version (e.g. for OpenShift with distributionVersion with value 4.17.0, status.version should be 1.30.4).

All logic that makes a decision based on evaluating the kubernetes version should rely on the status field instead of the spec field.

Related:

#11564

/cc @fabriziopandini @enxebre @sbueringer

Anything else you would like to add?

No response

Label(s) to be applied

/kind feature
/area api

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/apiIssues or PRs related to the APIskind/featureCategorizes issue or PR as related to a new feature.needs-priorityIndicates an issue lacks a `priority/foo` label and requires one.needs-triageIndicates an issue or PR lacks a `triage/foo` label and requires one.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions