Skip to main content

ipam_resource_discovery_associations

Creates, updates, deletes or gets an ipam_resource_discovery_association resource or lists ipam_resource_discovery_associations in a region

Overview

Nameipam_resource_discovery_associations
TypeResource
DescriptionResource Schema of AWS::EC2::IPAMResourceDiscoveryAssociation Type
Idaws.ec2.ipam_resource_discovery_associations

Fields

NameDatatypeDescription
ipam_arnstringArn of the IPAM.
ipam_regionstringThe home region of the IPAM.
ipam_resource_discovery_association_idstringId of the IPAM Resource Discovery Association.
ipam_resource_discovery_idstringThe Amazon Resource Name (ARN) of the IPAM Resource Discovery Association.
ipam_idstringThe Id of the IPAM this Resource Discovery is associated to.
ipam_resource_discovery_association_arnstringThe Amazon Resource Name (ARN) of the resource discovery association is a part of.
is_defaultbooleanIf the Resource Discovery Association exists due as part of CreateIpam.
owner_idstringThe AWS Account ID for the account where the shared IPAM exists.
statestringThe operational state of the Resource Discovery Association. Related to Create/Delete activities.
resource_discovery_statusstringThe status of the resource discovery.
tagsarrayAn array of key-value pairs to apply to this resource.
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTIpamId, IpamResourceDiscoveryId, region
delete_resourceDELETEdata__Identifier, region
update_resourceUPDATEdata__Identifier, data__PatchDocument, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all ipam_resource_discovery_associations in a region.

SELECT
region,
ipam_arn,
ipam_region,
ipam_resource_discovery_association_id,
ipam_resource_discovery_id,
ipam_id,
ipam_resource_discovery_association_arn,
is_default,
owner_id,
state,
resource_discovery_status,
tags
FROM aws.ec2.ipam_resource_discovery_associations
WHERE region = 'us-east-1';

Gets all properties from an individual ipam_resource_discovery_association.

SELECT
region,
ipam_arn,
ipam_region,
ipam_resource_discovery_association_id,
ipam_resource_discovery_id,
ipam_id,
ipam_resource_discovery_association_arn,
is_default,
owner_id,
state,
resource_discovery_status,
tags
FROM aws.ec2.ipam_resource_discovery_associations
WHERE region = 'us-east-1' AND data__Identifier = '<IpamResourceDiscoveryAssociationId>';

INSERT example

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

/*+ create */
INSERT INTO aws.ec2.ipam_resource_discovery_associations (
IpamResourceDiscoveryId,
IpamId,
region
)
SELECT
'{{ IpamResourceDiscoveryId }}',
'{{ IpamId }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM aws.ec2.ipam_resource_discovery_associations
WHERE data__Identifier = '<IpamResourceDiscoveryAssociationId>'
AND region = 'us-east-1';

Permissions

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

Create

ec2:AssociateIpamResourceDiscovery,
ec2:DescribeIpamResourceDiscoveryAssociations,
ec2:CreateTags

Read

ec2:DescribeIpamResourceDiscoveryAssociations

Update

ec2:DescribeIpamResourceDiscoveryAssociations,
ec2:CreateTags,
ec2:DeleteTags

Delete

ec2:DisassociateIpamResourceDiscovery,
ec2:DescribeIpamResourceDiscoveryAssociations,
ec2:DeleteTags

List

ec2:DescribeIpamResourceDiscoveryAssociations