get Peering Attachment
suspend fun getPeeringAttachment(argument: GetPeeringAttachmentPlainArgs): GetPeeringAttachmentResult
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());
}
}
Content copied to clipboard
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());
}
}
Content copied to clipboard
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.
See also
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.
suspend fun getPeeringAttachment(argument: suspend GetPeeringAttachmentPlainArgsBuilder.() -> Unit): GetPeeringAttachmentResult
Return
A collection of values returned by getPeeringAttachment.
See also
Parameters
argument
Builder for com.pulumi.aws.ec2transitgateway.kotlin.inputs.GetPeeringAttachmentPlainArgs.