aws.ec2transitgateway.getConnectPeer
Explore with Pulumi AI
Get information on an EC2 Transit Gateway Connect Peer.
Example Usage
By Filter
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = Aws.Ec2TransitGateway.GetConnectPeer.Invoke(new()
{
Filters = new[]
{
new Aws.Ec2TransitGateway.Inputs.GetConnectPeerFilterInputArgs
{
Name = "transit-gateway-attachment-id",
Values = new[]
{
"tgw-attach-12345678",
},
},
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ec2transitgateway"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2transitgateway.LookupConnectPeer(ctx, &ec2transitgateway.LookupConnectPeerArgs{
Filters: []ec2transitgateway.GetConnectPeerFilter{
{
Name: "transit-gateway-attachment-id",
Values: []string{
"tgw-attach-12345678",
},
},
},
}, nil)
if err != nil {
return err
}
return nil
})
}
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.GetConnectPeerArgs;
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.getConnectPeer(GetConnectPeerArgs.builder()
.filters(GetConnectPeerFilterArgs.builder()
.name("transit-gateway-attachment-id")
.values("tgw-attach-12345678")
.build())
.build());
}
}
import pulumi
import pulumi_aws as aws
example = aws.ec2transitgateway.get_connect_peer(filters=[aws.ec2transitgateway.GetConnectPeerFilterArgs(
name="transit-gateway-attachment-id",
values=["tgw-attach-12345678"],
)])
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = aws.ec2transitgateway.getConnectPeer({
filters: [{
name: "transit-gateway-attachment-id",
values: ["tgw-attach-12345678"],
}],
});
variables:
example:
fn::invoke:
Function: aws:ec2transitgateway:getConnectPeer
Arguments:
filters:
- name: transit-gateway-attachment-id
values:
- tgw-attach-12345678
By Identifier
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = Aws.Ec2TransitGateway.GetConnectPeer.Invoke(new()
{
TransitGatewayConnectPeerId = "tgw-connect-peer-12345678",
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ec2transitgateway"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2transitgateway.LookupConnectPeer(ctx, &ec2transitgateway.LookupConnectPeerArgs{
TransitGatewayConnectPeerId: pulumi.StringRef("tgw-connect-peer-12345678"),
}, nil)
if err != nil {
return err
}
return nil
})
}
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.GetConnectPeerArgs;
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.getConnectPeer(GetConnectPeerArgs.builder()
.transitGatewayConnectPeerId("tgw-connect-peer-12345678")
.build());
}
}
import pulumi
import pulumi_aws as aws
example = aws.ec2transitgateway.get_connect_peer(transit_gateway_connect_peer_id="tgw-connect-peer-12345678")
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = aws.ec2transitgateway.getConnectPeer({
transitGatewayConnectPeerId: "tgw-connect-peer-12345678",
});
variables:
example:
fn::invoke:
Function: aws:ec2transitgateway:getConnectPeer
Arguments:
transitGatewayConnectPeerId: tgw-connect-peer-12345678
Using getConnectPeer
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getConnectPeer(args: GetConnectPeerArgs, opts?: InvokeOptions): Promise<GetConnectPeerResult>
function getConnectPeerOutput(args: GetConnectPeerOutputArgs, opts?: InvokeOptions): Output<GetConnectPeerResult>
def get_connect_peer(filters: Optional[Sequence[GetConnectPeerFilter]] = None,
tags: Optional[Mapping[str, str]] = None,
transit_gateway_connect_peer_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetConnectPeerResult
def get_connect_peer_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetConnectPeerFilterArgs]]]] = None,
tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
transit_gateway_connect_peer_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetConnectPeerResult]
func LookupConnectPeer(ctx *Context, args *LookupConnectPeerArgs, opts ...InvokeOption) (*LookupConnectPeerResult, error)
func LookupConnectPeerOutput(ctx *Context, args *LookupConnectPeerOutputArgs, opts ...InvokeOption) LookupConnectPeerResultOutput
> Note: This function is named LookupConnectPeer
in the Go SDK.
public static class GetConnectPeer
{
public static Task<GetConnectPeerResult> InvokeAsync(GetConnectPeerArgs args, InvokeOptions? opts = null)
public static Output<GetConnectPeerResult> Invoke(GetConnectPeerInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetConnectPeerResult> getConnectPeer(GetConnectPeerArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: aws:ec2transitgateway/getConnectPeer:getConnectPeer
arguments:
# arguments dictionary
The following arguments are supported:
- Filters
List<Get
Connect Peer Filter> One or more configuration blocks containing name-values filters. Detailed below.
- Dictionary<string, string>
Key-value tags for the EC2 Transit Gateway Connect Peer
- Transit
Gateway stringConnect Peer Id Identifier of the EC2 Transit Gateway Connect Peer.
- Filters
[]Get
Connect Peer Filter One or more configuration blocks containing name-values filters. Detailed below.
- map[string]string
Key-value tags for the EC2 Transit Gateway Connect Peer
- Transit
Gateway stringConnect Peer Id Identifier of the EC2 Transit Gateway Connect Peer.
- filters
List<Get
Connect Peer Filter> One or more configuration blocks containing name-values filters. Detailed below.
- Map<String,String>
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit
Gateway StringConnect Peer Id Identifier of the EC2 Transit Gateway Connect Peer.
- filters
Get
Connect Peer Filter[] One or more configuration blocks containing name-values filters. Detailed below.
- {[key: string]: string}
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit
Gateway stringConnect Peer Id Identifier of the EC2 Transit Gateway Connect Peer.
- filters
Sequence[Get
Connect Peer Filter] One or more configuration blocks containing name-values filters. Detailed below.
- Mapping[str, str]
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit_
gateway_ strconnect_ peer_ id Identifier of the EC2 Transit Gateway Connect Peer.
- filters List<Property Map>
One or more configuration blocks containing name-values filters. Detailed below.
- Map<String>
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit
Gateway StringConnect Peer Id Identifier of the EC2 Transit Gateway Connect Peer.
getConnectPeer Result
The following output properties are available:
- Arn string
EC2 Transit Gateway Connect Peer ARN
- Bgp
Asn string BGP ASN number assigned customer device
- Id string
The provider-assigned unique ID for this managed resource.
- Inside
Cidr List<string>Blocks CIDR blocks that will be used for addressing within the tunnel.
- Peer
Address string IP addressed assigned to customer device, which is used as tunnel endpoint
- Dictionary<string, string>
Key-value tags for the EC2 Transit Gateway Connect Peer
- Transit
Gateway stringAddress The IP address assigned to Transit Gateway, which is used as tunnel endpoint.
- Transit
Gateway stringAttachment Id The Transit Gateway Connect
- Transit
Gateway stringConnect Peer Id - Filters
List<Get
Connect Peer Filter>
- Arn string
EC2 Transit Gateway Connect Peer ARN
- Bgp
Asn string BGP ASN number assigned customer device
- Id string
The provider-assigned unique ID for this managed resource.
- Inside
Cidr []stringBlocks CIDR blocks that will be used for addressing within the tunnel.
- Peer
Address string IP addressed assigned to customer device, which is used as tunnel endpoint
- map[string]string
Key-value tags for the EC2 Transit Gateway Connect Peer
- Transit
Gateway stringAddress The IP address assigned to Transit Gateway, which is used as tunnel endpoint.
- Transit
Gateway stringAttachment Id The Transit Gateway Connect
- Transit
Gateway stringConnect Peer Id - Filters
[]Get
Connect Peer Filter
- arn String
EC2 Transit Gateway Connect Peer ARN
- bgp
Asn String BGP ASN number assigned customer device
- id String
The provider-assigned unique ID for this managed resource.
- inside
Cidr List<String>Blocks CIDR blocks that will be used for addressing within the tunnel.
- peer
Address String IP addressed assigned to customer device, which is used as tunnel endpoint
- Map<String,String>
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit
Gateway StringAddress The IP address assigned to Transit Gateway, which is used as tunnel endpoint.
- transit
Gateway StringAttachment Id The Transit Gateway Connect
- transit
Gateway StringConnect Peer Id - filters
List<Get
Connect Peer Filter>
- arn string
EC2 Transit Gateway Connect Peer ARN
- bgp
Asn string BGP ASN number assigned customer device
- id string
The provider-assigned unique ID for this managed resource.
- inside
Cidr string[]Blocks CIDR blocks that will be used for addressing within the tunnel.
- peer
Address string IP addressed assigned to customer device, which is used as tunnel endpoint
- {[key: string]: string}
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit
Gateway stringAddress The IP address assigned to Transit Gateway, which is used as tunnel endpoint.
- transit
Gateway stringAttachment Id The Transit Gateway Connect
- transit
Gateway stringConnect Peer Id - filters
Get
Connect Peer Filter[]
- arn str
EC2 Transit Gateway Connect Peer ARN
- bgp_
asn str BGP ASN number assigned customer device
- id str
The provider-assigned unique ID for this managed resource.
- inside_
cidr_ Sequence[str]blocks CIDR blocks that will be used for addressing within the tunnel.
- peer_
address str IP addressed assigned to customer device, which is used as tunnel endpoint
- Mapping[str, str]
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit_
gateway_ straddress The IP address assigned to Transit Gateway, which is used as tunnel endpoint.
- transit_
gateway_ strattachment_ id The Transit Gateway Connect
- transit_
gateway_ strconnect_ peer_ id - filters
Sequence[Get
Connect Peer Filter]
- arn String
EC2 Transit Gateway Connect Peer ARN
- bgp
Asn String BGP ASN number assigned customer device
- id String
The provider-assigned unique ID for this managed resource.
- inside
Cidr List<String>Blocks CIDR blocks that will be used for addressing within the tunnel.
- peer
Address String IP addressed assigned to customer device, which is used as tunnel endpoint
- Map<String>
Key-value tags for the EC2 Transit Gateway Connect Peer
- transit
Gateway StringAddress The IP address assigned to Transit Gateway, which is used as tunnel endpoint.
- transit
Gateway StringAttachment Id The Transit Gateway Connect
- transit
Gateway StringConnect Peer Id - filters List<Property Map>
Supporting Types
GetConnectPeerFilter
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
aws
Terraform Provider.