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

Set LicenseToken field only when version is greater than v0.22 #9264

Merged
merged 1 commit into from
Feb 20, 2025

Conversation

rahulbabu95
Copy link
Member

@rahulbabu95 rahulbabu95 commented Feb 19, 2025

Issue #, if available:
#2855

Description of changes:
LicenseToken field on cluster spec will be introduced in 'v0.22.0'. At present since we set this field when initialize the end-to-end test object it gets set even on the previous minor versions where it's not intended to. This change sets this field only on main, or if the version is higher than 'v0.22.0'. This change also cleans up some old cleanup code in our e2e framework that was used only during way old releases such as 'v0.6.1' and is no longer needed.

Currently see the upgrade from latest minor version tests failing with the below error:

cluster.go:939: Running shell command [ /usr/bin/sh -c bin/v0.21.6/eksctl-anywhere create cluster -f main-i-09dec-53a064b/main-i-09dec-53a064b-eks-a.yaml -v 6 ]
Error: the cluster config file provided is invalid: unable to parse main-i-09dec-53a064b/main-i-09dec-53a064b-eks-a.yaml file: error unmarshaling JSON: while decoding JSON: json: unknown field "licenseToken"
cluster.go:946: Command failed, scanning output for error
cluster.go:966: Command bin/v0.21.6/eksctl-anywhere [create cluster -f main-i-09dec-53a064b/main-i-09dec-53a064b-eks-a.yaml -v 6] failed with error: exit status 255: Error: the cluster config file provided is invalid: unable to parse main-i-09dec-53a064b/main-i-09dec-53a064b-eks-a.yaml file: error unmarshaling JSON: while decoding JSON: json: unknown field "licenseToken"

Testing (if applicable):
Verified that both simple flow and upgrade from minor flow works: https://tiny.amazon.com/14se0krtr/IsenLink

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@eks-distro-bot eks-distro-bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Feb 19, 2025
Copy link

codecov bot commented Feb 19, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 72.35%. Comparing base (2ec757c) to head (cb34257).
Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #9264   +/-   ##
=======================================
  Coverage   72.35%   72.35%           
=======================================
  Files         587      587           
  Lines       46140    46140           
=======================================
  Hits        33385    33385           
  Misses      11006    11006           
  Partials     1749     1749           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

LicenseToken field on cluster spec will be introduced in 'v0.22.0'.
At present since we set this field when initialize the end-to-end
test object it gets set even on the previous minor versions where
it's not intended to. This change sets this field only on main, or
if the version is higher than 'v0.22.0'. This change also cleans up
some old cleanup code in our e2e framework that was used only during
way old releases such as 'v0.6.1' and is no longer needed.

Signed-off-by: Rahul Ganesh <[email protected]>
@rahulbabu95 rahulbabu95 force-pushed the rel22/fix-latest-minor branch from 354242c to cb34257 Compare February 19, 2025 19:24
@sp1999
Copy link
Member

sp1999 commented Feb 19, 2025

/lgtm

@2ez4szliu
Copy link
Member

/approve

@eks-distro-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: 2ez4szliu

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm 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.

5 participants