Skip to main content

ipam_allocations

Used to retrieve a list of ipam_allocations in a region or to create or delete a ipam_allocations resource, use ipam_allocation to read or update an individual resource.

Overview

Nameipam_allocations
TypeResource
DescriptionResource Schema of AWS::EC2::IPAMAllocation Type
Idaws.ec2.ipam_allocations

Fields

NameDatatypeDescription
ipam_pool_idstringId of the IPAM Pool.
ipam_pool_allocation_idstringId of the allocation.
cidrundefined
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTIpamPoolId, region
delete_resourceDELETEdata__Identifier, region
list_resourceSELECTregion

SELECT Example

SELECT
region,
ipam_pool_id,
ipam_pool_allocation_id,
cidr
FROM aws.ec2.ipam_allocations
WHERE region = 'us-east-1';

INSERT Example

Use the following StackQL query and manifest file to create a new ipam_allocation resource, using stack-deploy.

/*+ create */
INSERT INTO aws.ec2.ipam_allocations (
IpamPoolId,
region
)
SELECT
'{{ IpamPoolId }}',
'{{ region }}';

DELETE Example

/*+ delete */
DELETE FROM aws.ec2.ipam_allocations
WHERE data__Identifier = '<IpamPoolId|IpamPoolAllocationId|Cidr>'
AND region = 'us-east-1';

Permissions

To operate on the ipam_allocations resource, the following permissions are required:

Create

ec2:AllocateIpamPoolCidr,
ec2:GetIpamPoolAllocations

Delete

ec2:ReleaseIpamPoolAllocation

List

ec2:GetIpamPoolAllocations