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

eks: Amazon Linux 2023 support #29334

Closed
2 tasks
pahud opened this issue Mar 1, 2024 · 1 comment · Fixed by #29335
Closed
2 tasks

eks: Amazon Linux 2023 support #29334

pahud opened this issue Mar 1, 2024 · 1 comment · Fixed by #29335
Assignees
Labels
@aws-cdk/aws-eks Related to Amazon Elastic Kubernetes Service feature-request A feature should be added or improved. p2

Comments

@pahud
Copy link
Contributor

pahud commented Mar 1, 2024

Describe the feature

https://aws.amazon.com/about-aws/whats-new/2024/02/amazon-eks-support-linux-2023/
https://docs.aws.amazon.com/eks/latest/userguide/eks-optimized-ami.html

I will create a PR for this.

Use Case

To support Amazon Linux 2023 nodegroup AMI.

Proposed Solution

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-nodegroup.html#cfn-eks-nodegroup-amitype

No response

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

v2.130.0

Environment details (OS name and version, etc.)

all

@pahud pahud added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Mar 1, 2024
@pahud pahud self-assigned this Mar 1, 2024
@pahud pahud added p2 @aws-cdk/aws-eks Related to Amazon Elastic Kubernetes Service and removed needs-triage This issue or PR still needs to be triaged. labels Mar 1, 2024
@mergify mergify bot closed this as completed in #29335 Mar 1, 2024
mergify bot pushed a commit that referenced this issue Mar 1, 2024
### 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*
Copy link

github-actions bot commented Mar 1, 2024

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-eks Related to Amazon Elastic Kubernetes Service feature-request A feature should be added or improved. p2
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant