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

update version skew policy #833

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Conversation

justdan96
Copy link

@justdan96 justdan96 commented Sep 16, 2024

What this PR does / why we need it:
This commit updates the version skew policy to match this document: https://kubernetes.io/releases/version-skew-policy/

Which issue(s) this PR fixes
Issue #834

Special notes for your reviewer:

Checklist:

  • squashed commits into logical changes
  • includes documentation
  • adds unit tests
  • adds or updates e2e tests
  • backport needed

This commit updates the version skew policy to match this document: https://kubernetes.io/releases/version-skew-policy/
@justdan96 justdan96 requested a review from a team as a code owner September 16, 2024 15:59
@furkatgofurov7
Copy link
Contributor

@mjura @yiannistri folks, can you please take a look when you have time? Thanks

@yiannistri
Copy link
Contributor

@justdan96 thank you for the PR, could you also add tests that cover this change? I'll review the change itself in the meantime.

@justdan96
Copy link
Author

@yiannistri test added

@yiannistri
Copy link
Contributor

@mjura I've tested this change locally and it looks fine from my point of view. Can you please also review?

Copy link
Contributor

@mjura mjura left a comment

Choose a reason for hiding this comment

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

We don't want to differentiate between version => v1.25 and lower < v1.25

@@ -353,11 +353,16 @@ func validateUpdate(config *eksv1.EKSClusterConfig) error {
if clusterVersion.EQ(*version) {
continue
}
if clusterVersion.Minor-version.Minor == 1 {
if (clusterVersion.Minor < 25 && clusterVersion.Minor-version.Minor <= 2) || (clusterVersion.Minor >= 25 && clusterVersion.Minor-version.Minor <= 3) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Why it has to be lower than 25? We already dropped support for Kubernetes lower than 27. It doesn't make sense to me

continue
}
errs = append(errs, fmt.Sprintf("versions for cluster [%s] and nodegroup [%s] not compatible: all nodegroup kubernetes versions"+
"must be equal to or one minor version lower than the cluster kubernetes version", aws.ToString(config.Spec.KubernetesVersion), aws.ToString(ng.Version)))
if clusterVersion.Minor < 25 {
Copy link
Contributor

Choose a reason for hiding this comment

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

Again this same question, why 25 ?

errs = append(errs, fmt.Sprintf("versions for cluster [%s] and nodegroup [%s] not compatible: all nodegroup kubernetes versions"+
"must be equal to or one minor version lower than the cluster kubernetes version", aws.ToString(config.Spec.KubernetesVersion), aws.ToString(ng.Version)))
if clusterVersion.Minor < 25 {
errs = append(errs, fmt.Sprintf("versions for cluster [%s] and node group [%s] are not compatible: for clusters running Kubernetes < 1.25 the "+
Copy link
Contributor

Choose a reason for hiding this comment

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

We already dropped support for Kubernetes lower than 1.27

@justdan96
Copy link
Author

justdan96 commented Sep 27, 2024

I can't find a list of supported versions in this repo, are you talking about Rancher itself? Even if that's the case the v.2.8.x line still supports K8s 1.25.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: PR to be reviewed
Development

Successfully merging this pull request may close these issues.

4 participants