[Enhancement]: EIP support for AWS provided public IP Pools #39449
Labels
enhancement
Requests to existing resources that expand the functionality or scope.
service/ec2
Issues and PRs that pertain to the ec2 service.
service/ipam
Issues and PRs that pertain to the ipam service.
Milestone
Description
I am unsure if this needs to be an enhancement or a bug so apologies in advance if enhancement is the wrong label.
AWS recently announced the ability to request Amazon-provided contiguous IPv4 blocks via their IPAM service. This allows you to request a public IP CIDR block and then allocate those to Elastic IP's to then be used for EC2 resources. I was able to follow their guide and create the resources via Terraform. I was able to create an IPAM, create a public IP pool provided by Amazon, and create a continuous CIDR block of IP's. The issue occurs when I try to create an EIP (elastic IP) resource specifying use of that pool. I included AWS links on how to do this via AWS CLI in the references section. It looks like there is a new property called "ipam-pool-id" which is not the same as "public_ipv_4_pool".
There seems to be a new property called ipam-pool-id which is not a current option in the aws_eip resource.
This is availabe in AWS CLI specifying the IPAM pool ID.
aws ec2 allocate-address --region us-east-1 --ipam-pool-id ipam-pool-{unique_aws_resource_value}
Terraform code sample to create the IPAM pool:
The current resource property "public_ipv4_pool" not the same as the CLI property "ipam-pool-id"
Affected Resource(s) and/or Data Source(s)
Potential Terraform Configuration
References
https://aws.amazon.com/about-aws/whats-new/2024/08/amazon-provided-contiguous-ipv4-blocks/
https://docs.aws.amazon.com/vpc/latest/ipam/tutorials-eip-pool.html
Would you like to implement a fix?
None
The text was updated successfully, but these errors were encountered: