Data Source: awsEc2TransitGatewayAttachment
Get information on an EC2 Transit Gateway's attachment to a resource.
Example Usage
/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
new aws.dataAwsEc2TransitGatewayAttachment.DataAwsEc2TransitGatewayAttachment(
this,
"example",
{
filter: [
{
name: "transit-gateway-id",
values: ["${aws_ec2_transit_gateway.example.id}"],
},
{
name: "resource-type",
values: ["peering"],
},
],
}
);
Argument Reference
The following arguments are supported:
filter
- (Optional) One or more configuration blocks containing name-values filters. Detailed below.transitGatewayAttachmentId
- (Optional) ID of the attachment.
filter Argument Reference
name
- (Required) Name of the field to filter by, as defined by the underlying AWS API.values
- (Required) List of one or more values for the filter.
Attribute Reference
In addition to all arguments above, the following attributes are exported:
arn
- ARN of the attachment.associationState
- The state of the association (see the underlying AWS API for valid values).associationTransitGatewayRouteTableId
- The ID of the route table for the transit gateway.resourceId
- ID of the resource.resourceOwnerId
- ID of the AWS account that owns the resource.resourceType
- Resource type.state
- Attachment state.tags
- Key-value tags for the attachment.transitGatewayId
- ID of the transit gateway.transitGatewayOwnerId
- The ID of the AWS account that owns the transit gateway.