Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(eks): support Amazon Linux 2023 (#29335)
### Issue # (if applicable) Closes #29334 ### Reason for this change To support Amazon Linux 2023 nodegroup. ### Description of changes Allow the AmiType to select Amazon Linux 2023 for both x86_64 and ARM_64. ### Description of how you validated changes ```ts const mastersRole = new iam.Role(this, 'AdminRole', { assumedBy: new iam.AccountRootPrincipal(), }); const vpc = ec2.Vpc.fromLookup(this, 'Vpc', { isDefault: true }); const cluster = new eks.Cluster(this, 'Cluster', { vpc, mastersRole, kubectlLayer: new KubectlV29Layer(this, 'KubectlLayer'), version: eks.KubernetesVersion.V1_29, defaultCapacity: 0, }); cluster.addNodegroupCapacity('NG-X86', { amiType: eks.NodegroupAmiType.AL2023_X86_64_STANDARD, desiredSize: 1, }); cluster.addNodegroupCapacity('NG-ARM', { amiType: eks.NodegroupAmiType.AL2023_ARM_64_STANDARD, desiredSize: 1, }); ``` ```sh $ /tmp/kubectl get no NAME STATUS ROLES AGE VERSION ip-172-31-1-222.ec2.internal Ready <none> 4m53s v1.29.0-eks-5e0fdde ip-172-31-2-242.ec2.internal Ready <none> 4m46s v1.29.0-eks-5e0fdde ``` ``` $ /tmp/kubectl get nodes ip-172-31-1-222.ec2.internal -o jsonpath="{ .status.nodeInfo}" | jq -r . { "architecture": "amd64", "bootID": "f65b39c5-f1c6-4b75-8f62-8424c29302ca", "containerRuntimeVersion": "containerd://1.7.11", "kernelVersion": "6.1.77-99.164.amzn2023.x86_64", "kubeProxyVersion": "v1.29.0-eks-5e0fdde", "kubeletVersion": "v1.29.0-eks-5e0fdde", "machineID": "ec23037a57eb6be59d03137fbe1c2625", "operatingSystem": "linux", "osImage": "Amazon Linux 2023", "systemUUID": "ec23037a-57eb-6be5-9d03-137fbe1c2625" } $ /tmp/kubectl get nodes ip-172-31-2-242.ec2.internal -o jsonpath="{ .status.nodeInfo}" | jq -r . { "architecture": "arm64", "bootID": "a2d15e6f-c48c-474b-aad5-510712c41153", "containerRuntimeVersion": "containerd://1.7.11", "kernelVersion": "6.1.77-99.164.amzn2023.aarch64", "kubeProxyVersion": "v1.29.0-eks-5e0fdde", "kubeletVersion": "v1.29.0-eks-5e0fdde", "machineID": "ec2b26d85fe443884398704c3b82887b", "operatingSystem": "linux", "osImage": "Amazon Linux 2023", "systemUUID": "ec2b26d8-5fe4-4388-4398-704c3b82887b" } ``` ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.md) ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
- Loading branch information