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

[aws-eks] - CDK support for Custom AMI Support for EKS Managed Nodes feature #9873

Closed
2 tasks
haofeif opened this issue Aug 20, 2020 · 9 comments · Fixed by #9881
Closed
2 tasks

[aws-eks] - CDK support for Custom AMI Support for EKS Managed Nodes feature #9873

haofeif opened this issue Aug 20, 2020 · 9 comments · Fixed by #9881
Assignees
Labels
@aws-cdk/aws-eks Related to Amazon Elastic Kubernetes Service effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p1

Comments

@haofeif
Copy link

haofeif commented Aug 20, 2020

Amazon Elastic Kubernetes Service (EKS) now supports EC2 Launch Templates and custom AMIs for managed node groups. When combined, these new features provide flexible configuration and customization options for Amazon EC2 instances which are managed as Kubernetes nodes by EKS. This enables you to leverage the simplicity of managed node provisioning and lifecycle management features while adhering to any level of customization, compliance, or security requirements.

https://aws.amazon.com/blogs/containers/introducing-launch-template-and-custom-ami-support-in-amazon-eks-managed-node-groups/

Use Case

Customers who needs Custom AMI to clear the blocker to adopt the EKS Managed Node Group solution, is now available to use the new feature provided from the EKS Managed Node Group.
However, the CDK currently yet to support the feature.

Proposed Solution

Other

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

This is a 🚀 Feature Request

@haofeif haofeif added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Aug 20, 2020
@github-actions github-actions bot added the @aws-cdk/aws-eks Related to Amazon Elastic Kubernetes Service label Aug 20, 2020
@pahud
Copy link
Contributor

pahud commented Aug 20, 2020

I am the original contributor of the managed nodegroup. I'll try extend it with the custom AMI support with a new PR.

@iliapolo iliapolo added effort/large Large work item – several weeks of effort p1 effort/medium Medium work item – several days of effort and removed needs-triage This issue or PR still needs to be triaged. effort/large Large work item – several weeks of effort labels Aug 21, 2020
@SomayaB SomayaB added the in-progress This issue is being actively worked on. label Aug 22, 2020
@haofeif
Copy link
Author

haofeif commented Aug 28, 2020

@pahud @SomayaB Hi, i saw that the change not released in the cdk 1.61. Is this expected to be released in the next cdk version 1.62 ?

@pahud
Copy link
Contributor

pahud commented Aug 28, 2020

Hi @haofeif

We are still pending this PR for approval. #9881

@mergify mergify bot closed this as completed in #9881 Sep 9, 2020
mergify bot pushed a commit that referenced this issue Sep 9, 2020
…ort (#9881)

- This PR allows you to:
1. use `LaunchTemplate` for the managed nodegroups
2. specify custom AMI in the `LaunchTemplate`

- `prop.vpc` of Pinger is now `ec2.IVpc`
- bump cluster k8s version in the integration testing from `1.16` to `1.17`

Closes: #9873 
Closes: #9924

## Note

At this moment we use the property override to make it work. When cfn spec is updated we can use `CfnNodeGroup` to specify launch template natively, which should be backward-compatible with no breaking changes.

Users will need to create `CfnLaunchTemplate` resource and pass the resource as the property to the nodegroup untill we support the LaunchTemplate L2(#6734).

## TODO

- [x] integ testing
- [x] unit testing
- [x] update README


----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
@iliapolo iliapolo removed the in-progress This issue is being actively worked on. label Sep 9, 2020
@boazsilverman
Copy link

Reading these comments, it seems to me that there currently is a possibility to use CDK for creating nodes with custom AMI. Can someone please explain how to do this?
Thanks

@boazsilverman
Copy link

boazsilverman commented Jun 21, 2021 via email

@boazsilverman
Copy link

boazsilverman commented Jun 21, 2021 via email

@iliapolo
Copy link
Contributor

@boazsilverman

Hey, when trying to apply exactly the same logic, just in Python, here is
the result I got:
[image: image.png]

Looks like the image didn't upload.

If you feel you are encountering a bug, please open a separate issue with the reproduction and the error message.
In the meantime I can offer this: https://docs.aws.amazon.com/cdk/api/latest/python/aws_cdk.aws_eks/README.html#launch-template-support

@alainms25
Copy link

Hi, I need to define userdata for nodegroups with cdk. It is possible to perform that action without having to work with a custom ami.

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 effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p1
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants