getPeeringAttachment

Get information on an EC2 Transit Gateway Peering Attachment.

Example Usage

By Filter

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2transitgateway.Ec2transitgatewayFunctions;
import com.pulumi.aws.ec2transitgateway.inputs.GetPeeringAttachmentArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var example = Ec2transitgatewayFunctions.getPeeringAttachment(GetPeeringAttachmentArgs.builder()
.filters(GetPeeringAttachmentFilterArgs.builder()
.name("transit-gateway-attachment-id")
.values("tgw-attach-12345678")
.build())
.build());
}
}

By Identifier

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2transitgateway.Ec2transitgatewayFunctions;
import com.pulumi.aws.ec2transitgateway.inputs.GetPeeringAttachmentArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var attachment = Ec2transitgatewayFunctions.getPeeringAttachment(GetPeeringAttachmentArgs.builder()
.id("tgw-attach-12345678")
.build());
}
}

Return

A collection of values returned by getPeeringAttachment.

Parameters

argument

A collection of arguments for invoking getPeeringAttachment.


suspend fun getPeeringAttachment(filters: List<GetPeeringAttachmentFilter>? = null, id: String? = null, tags: Map<String, String>? = null): GetPeeringAttachmentResult

Return

A collection of values returned by getPeeringAttachment.

Parameters

filters

One or more configuration blocks containing name-values filters. Detailed below.

id

Identifier of the EC2 Transit Gateway Peering Attachment.

tags

Mapping of tags, each pair of which must exactly match a pair on the specific EC2 Transit Gateway Peering Attachment to retrieve. More complex filters can be expressed using one or more filter sub-blocks, which take the following arguments:

See also


Return

A collection of values returned by getPeeringAttachment.

Parameters

argument

Builder for com.pulumi.aws.ec2transitgateway.kotlin.inputs.GetPeeringAttachmentPlainArgs.

See also