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

add a new cdk example that allow us to use ipam pool id in a L2 vpc construct (ec2.vpc) #708

Closed
wants to merge 3 commits into from

Conversation

Crycham
Copy link

@Crycham Crycham commented Aug 8, 2022

Solving the issue : no parameter for ipam pool id in ec2.vpc :

aws/aws-cdk#21333

Fixes #


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Hicham Fellah added 2 commits August 8, 2022 12:39
…onstruct (ec2.vpc) solving the issue : no parameter for ipam pool id in ec2.vpc
Copy link
Contributor

@indrora indrora left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A good start but the readme could use some work and the os.environ causes the build to break.

cidr_range = cidr_range,
region_cidr_range = region_cidr_range,
env=cdk.Environment(
account=os.environ["CDK_DEFAULT_ACCOUNT"],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will result in a KeyError if this environment variable is not set.

Handle this better: os.getenv(k, default) does not throw an exception and provides a default value.


The deployement provides a VPC with 2 subnets ( private and public ) on each availability zone ( you could customize your VPC by modifying the vpc_stack.py code )
The Ipam_stack have a cidr_range for the top level ipam pool as "11.0.0.0/8" and "11.0.0.0/12" for the region ipam pool you can modify the two variable in app.py

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tell the user what the value of this is. Tell the user what they should be able to see/do with this. how can the customer see the two VPCs in each AZ?.

Comment on lines +4 to +7
This is cdk example project for CDK development with Python.

The project provides a solution that I already suggested for the issues reported from aws-cdk issues about using IPAM pool id in the ec2.vpc L2 construct :
https://github.com/aws/aws-cdk/issues/21333
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
This is cdk example project for CDK development with Python.
The project provides a solution that I already suggested for the issues reported from aws-cdk issues about using IPAM pool id in the ec2.vpc L2 construct :
https://github.com/aws/aws-cdk/issues/21333
This project demonstrates using IPAM pool in Amazon EC2 VPCs.

@indrora
Copy link
Contributor

indrora commented Jun 29, 2023

This PR is so old that if it doesn't easily get resolved in the next few weeks I'm likely to close it.

@kaiz-io kaiz-io closed this Sep 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants