You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(Instead of trying to re-interpret the current logic, I'll defer to describing the intended logic)
--custom-ami-id argument should be added for users to pass a custom AMI ID.
When performing an upgrade of EKS and/or self-managed nodegroups, the process for determining the appropriate AMI should follow:
Self-managed nodegroup
If --custom-ami-id has been supplied with a value, simply proceed to grab each ASG and its LT and create a new LT version with the AMI ID provided. If --custom-ami-id has NOT been supplied:
Get the launch template of each self-managed autoscaling group (we are ignoring support for launch configuration since its EOL)
From the LTs, extract the AMI ID
Perform a describe call on the AMI to determine if this is an Amazon EKS optimized AMI, and of which variant (AL2, Bottlerocket, Windows variants) and arch (x86/arm64)
If this is NOT an Amazon EKS optimized AMI, and --custom-ami-id has not been supplied, halt progress and return details to user that a custom AMI ID is required when an Amazon EKS optimized AMI is not currently in use
If this is an Amazon EKS optimized AMI, retrieve the AMI ID of the next incremental Kubernetes version from the associated SSM parameter (get the AMI ID for the next version of K8s for the given AMI variant and arch)
Create a new LT version with the new AMI ID, update the ASG, etc. (roll out changes)
EKS managed nodegroup
Default launch template
No-op from an AMI perspective; once the nodegroup Kubneretes version has been updated, the managed nodegroup will pull the appropriate AMI and deploy
Custom launch template
Get the ASGs from each of the EKS managed nodegroups
If there is NOT an AMI ID specified on the nodegroup, then the AMIs used are the EKS optimized AMIs - update the nodegroup version to the next incremental Kubernetes version and roll out changes
If there is an AMI ID specified on the nodegroup, this is a custom AMI and the user should have provided a --custom-ami-id, otherwise abort and report (nice rhyme!)
Solution/User Experience
The logic used for determining an AMI ID should be consistent and reliable without assumptions
Use case
(Instead of trying to re-interpret the current logic, I'll defer to describing the intended logic)
--custom-ami-idargument should be added for users to pass a custom AMI ID.When performing an upgrade of EKS and/or self-managed nodegroups, the process for determining the appropriate AMI should follow:
Self-managed nodegroup
If
--custom-ami-idhas been supplied with a value, simply proceed to grab each ASG and its LT and create a new LT version with the AMI ID provided. If--custom-ami-idhas NOT been supplied:--custom-ami-idhas not been supplied, halt progress and return details to user that a custom AMI ID is required when an Amazon EKS optimized AMI is not currently in useEKS managed nodegroup
Default launch template
Custom launch template
--custom-ami-id, otherwise abort and report (nice rhyme!)Solution/User Experience
The logic used for determining an AMI ID should be consistent and reliable without assumptions
Alternative solutions
No response