Repository navigation
Add support for AmazonLinux2027 custom AMIs - #8920
Draft
maitreya526 wants to merge 1 commit into
Draft
maitreya526 wants to merge 1 commit into
maitreya526 wants to merge 1 commit into
Conversation
AmazonLinux2027 nodes are named by EC2 instance ID, so the EC2_LINUX
access entry and the {{EC2PrivateDNSName}} aws-auth username eksctl
uses don't match and the nodes are rejected. Add an AmazonLinux2027
family for self-managed nodegroups that uses an EC2 access entry or a
{{SessionName}} aws-auth mapping, reuses the AmazonLinux2023 nodeadm
user data, and requires an AMI ID. Managed nodegroups are rejected
until EKS supports AmazonLinux2027.
Contributor
|
Hello maitreya526 👋 Thank you for opening a Pull Request in |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds an
AmazonLinux2027AMI family so self-managed nodegroups can run the AmazonLinux2027 EKS AMI preview with a custom AMI ID.Problem. AmazonLinux2027 AMIs bootstrap with nodeadm, like AmazonLinux2023, but nodeadm names AmazonLinux2027 nodes by EC2 instance ID (
i-0abc...) instead of by private DNS name. eksctl gives self-managed Linux nodegroups anEC2_LINUXaccess entry, or anaws-authmapping, with the usernamesystem:node:{{EC2PrivateDNSName}}. That doesn't match the node name, so the node authorizer rejects the node:Change. For
amiFamily: AmazonLinux2027on self-managed nodegroups (nodeGroups), eksctl now:EC2access entry instead ofEC2_LINUX, or anaws-authmapping with the usernamesystem:node:{{SessionName}}. The EKS docs describeEC2as the type for self-managed nodes that use the instance ID as the node name, mapped tosystem:node:{{SessionName}}.amito be an AMI ID, because there is no public SSM parameter for AmazonLinux2027 AMIs yetNot included, on purpose:
EC2_LINUX, so AmazonLinux2027 nodes wouldn't join. This can be lifted once EKS managed nodegroups support AmazonLinux2027.eksctl utils migrate-to-access-entryis unchanged. Fargate pod execution roles and hybrid node roles also usesystem:node:{{SessionName}}, so the migrator can't tell them apart from AmazonLinux2027 node roles, and an access entry's type can't be changed later. It keeps skipping these mappings with a warning and doesn't switch to API mode. Users can create theEC2access entry for the AmazonLinux2027 node role themselves and rerun the migration.ami: autolookup, arm64, GPU and Neuron AMIs, Outposts, and Karpenter, until those AMIs and lookup paths exist.Testing
Unit tests:
make unit-test-no-generatepasses. New tests cover the access entry type, theaws-authusername, validation (AMI ID required, dockerd rejected, managed nodegroups rejected), the containerd default, the user data, and the migrator skipping{{SessionName}}mappings.Manual test on a 1.37 cluster (
API_AND_CONFIG_MAP) with the public preview AMIami-0ad72f625c44b33e3(us-west-2), with no manual steps:A managed nodegroup with
amiFamily: AmazonLinux2027fails validation:The
aws-authpath (CONFIG_MAPclusters) is covered by unit tests. Asystem:node:{{SessionName}}mapping was also tested by hand on the same cluster and the node joined.Checklist
README.md, or theuserdocsdirectory)area/nodegroup) and kind (e.g.kind/improvement)BONUS POINTS checklist: complete for good vibes and maybe prizes?! 🤯