-
Notifications
You must be signed in to change notification settings - Fork 4k
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
EC2 Launch Template: Vpc Subnets support #14494
Comments
Hey @raimohanska, Thank you for making the request. This seems like a totally reasonable addition to the EC2 Construct Library. After a little digging I found that the feature you want exists in the L1 for EC2 through the If you feel comfortable adding this yourself, that will be the fastest way to get it added, otherwise someone from the dev team will take a look as time permits. 😸 😷 |
Thanks Noah! Good to get some validation for my idea. Unfortunately I cannot promise to be able to make time for implementing this myself, as it would most likely take quite a while to get up to speed with CDK development. It would for sure be an interesting challenge! I have patched this omission in the CDK by setting subnetId for the instance when creating it using the AWS SDK RunInstances. That's not the ideal solution as it requires an extra call during instance launch, but it does the trick for me for the time being. |
Bump. I'm trying to create a launch template through CDK and immediately noticed the l2 constructs were missing the most vital feature that you can do through the AWS console : specify network interfaces. I see this ticket is not assigned to anyone. Any chance of prioritizing it? |
Anybody kind enough to give me an example on how to specify subnet using |
Still no love for that lacking field? |
Argh still no solution for this ? |
+1 building Zscaler instance and there is a different ENI require for management and service interface. Can't use L2 for it |
This issue has received a significant amount of attention so we are automatically upgrading its priority. A member of the community will see the re-prioritization and provide an update on the issue. |
Would be great to be able to specify network interfaces for a LaunchTemplate.
Use Case
We are building an application where EC2 instances need to be launched/autoscaled in the application logic and the best abstraction for this would be to have a launch template that contains all the necessary details for launching an instance, without having to worry about things like subnets.
Proposed Solution
Include the vpcSubnets fields in LaunchTemplate, similarly to what you can do with an Instance.
Other
I'm not super deep into CDK/CloudFormation/EC2 details, so my proposed change may have the wrong abstractions. Still, being able to specify the networking configuration in a LaunchTemplate would be awesome. Just for reference, I've done the same thing earlierly with Terraform, which does support Network Interfaces in launch tempalates, as described in here.
Thanks for your great work!
This is a 🚀 Feature Request
The text was updated successfully, but these errors were encountered: