1. Packages
  2. AWS
  3. API Docs
  4. networkmanager
  5. TransitGatewayPeering
AWS v6.55.0 published on Monday, Oct 7, 2024 by Pulumi

aws.networkmanager.TransitGatewayPeering

Explore with Pulumi AI

aws logo
AWS v6.55.0 published on Monday, Oct 7, 2024 by Pulumi

    Creates a peering connection between an AWS Cloud WAN core network and an AWS Transit Gateway.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.networkmanager.TransitGatewayPeering("example", {
        coreNetworkId: exampleAwsccNetworkmanagerCoreNetwork.id,
        transitGatewayArn: exampleAwsEc2TransitGateway.arn,
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.networkmanager.TransitGatewayPeering("example",
        core_network_id=example_awscc_networkmanager_core_network["id"],
        transit_gateway_arn=example_aws_ec2_transit_gateway["arn"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := networkmanager.NewTransitGatewayPeering(ctx, "example", &networkmanager.TransitGatewayPeeringArgs{
    			CoreNetworkId:     pulumi.Any(exampleAwsccNetworkmanagerCoreNetwork.Id),
    			TransitGatewayArn: pulumi.Any(exampleAwsEc2TransitGateway.Arn),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Aws.NetworkManager.TransitGatewayPeering("example", new()
        {
            CoreNetworkId = exampleAwsccNetworkmanagerCoreNetwork.Id,
            TransitGatewayArn = exampleAwsEc2TransitGateway.Arn,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.networkmanager.TransitGatewayPeering;
    import com.pulumi.aws.networkmanager.TransitGatewayPeeringArgs;
    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) {
            var example = new TransitGatewayPeering("example", TransitGatewayPeeringArgs.builder()
                .coreNetworkId(exampleAwsccNetworkmanagerCoreNetwork.id())
                .transitGatewayArn(exampleAwsEc2TransitGateway.arn())
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:networkmanager:TransitGatewayPeering
        properties:
          coreNetworkId: ${exampleAwsccNetworkmanagerCoreNetwork.id}
          transitGatewayArn: ${exampleAwsEc2TransitGateway.arn}
    

    Create TransitGatewayPeering Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new TransitGatewayPeering(name: string, args: TransitGatewayPeeringArgs, opts?: CustomResourceOptions);
    @overload
    def TransitGatewayPeering(resource_name: str,
                              args: TransitGatewayPeeringArgs,
                              opts: Optional[ResourceOptions] = None)
    
    @overload
    def TransitGatewayPeering(resource_name: str,
                              opts: Optional[ResourceOptions] = None,
                              core_network_id: Optional[str] = None,
                              transit_gateway_arn: Optional[str] = None,
                              tags: Optional[Mapping[str, str]] = None)
    func NewTransitGatewayPeering(ctx *Context, name string, args TransitGatewayPeeringArgs, opts ...ResourceOption) (*TransitGatewayPeering, error)
    public TransitGatewayPeering(string name, TransitGatewayPeeringArgs args, CustomResourceOptions? opts = null)
    public TransitGatewayPeering(String name, TransitGatewayPeeringArgs args)
    public TransitGatewayPeering(String name, TransitGatewayPeeringArgs args, CustomResourceOptions options)
    
    type: aws:networkmanager:TransitGatewayPeering
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args TransitGatewayPeeringArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args TransitGatewayPeeringArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args TransitGatewayPeeringArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args TransitGatewayPeeringArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args TransitGatewayPeeringArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var transitGatewayPeeringResource = new Aws.NetworkManager.TransitGatewayPeering("transitGatewayPeeringResource", new()
    {
        CoreNetworkId = "string",
        TransitGatewayArn = "string",
        Tags = 
        {
            { "string", "string" },
        },
    });
    
    example, err := networkmanager.NewTransitGatewayPeering(ctx, "transitGatewayPeeringResource", &networkmanager.TransitGatewayPeeringArgs{
    	CoreNetworkId:     pulumi.String("string"),
    	TransitGatewayArn: pulumi.String("string"),
    	Tags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    })
    
    var transitGatewayPeeringResource = new TransitGatewayPeering("transitGatewayPeeringResource", TransitGatewayPeeringArgs.builder()
        .coreNetworkId("string")
        .transitGatewayArn("string")
        .tags(Map.of("string", "string"))
        .build());
    
    transit_gateway_peering_resource = aws.networkmanager.TransitGatewayPeering("transitGatewayPeeringResource",
        core_network_id="string",
        transit_gateway_arn="string",
        tags={
            "string": "string",
        })
    
    const transitGatewayPeeringResource = new aws.networkmanager.TransitGatewayPeering("transitGatewayPeeringResource", {
        coreNetworkId: "string",
        transitGatewayArn: "string",
        tags: {
            string: "string",
        },
    });
    
    type: aws:networkmanager:TransitGatewayPeering
    properties:
        coreNetworkId: string
        tags:
            string: string
        transitGatewayArn: string
    

    TransitGatewayPeering Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The TransitGatewayPeering resource accepts the following input properties:

    CoreNetworkId string
    The ID of a core network.
    TransitGatewayArn string
    The ARN of the transit gateway for the peering request.
    Tags Dictionary<string, string>
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    CoreNetworkId string
    The ID of a core network.
    TransitGatewayArn string
    The ARN of the transit gateway for the peering request.
    Tags map[string]string
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    coreNetworkId String
    The ID of a core network.
    transitGatewayArn String
    The ARN of the transit gateway for the peering request.
    tags Map<String,String>
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    coreNetworkId string
    The ID of a core network.
    transitGatewayArn string
    The ARN of the transit gateway for the peering request.
    tags {[key: string]: string}
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    core_network_id str
    The ID of a core network.
    transit_gateway_arn str
    The ARN of the transit gateway for the peering request.
    tags Mapping[str, str]
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    coreNetworkId String
    The ID of a core network.
    transitGatewayArn String
    The ARN of the transit gateway for the peering request.
    tags Map<String>
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the TransitGatewayPeering resource produces the following output properties:

    Arn string
    Peering Amazon Resource Name (ARN).
    CoreNetworkArn string
    The ARN of the core network.
    EdgeLocation string
    The edge location for the peer.
    Id string
    The provider-assigned unique ID for this managed resource.
    OwnerAccountId string
    The ID of the account owner.
    PeeringType string
    The type of peering. This will be TRANSIT_GATEWAY.
    ResourceArn string
    The resource ARN of the peer.
    TagsAll Dictionary<string, string>
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    TransitGatewayPeeringAttachmentId string
    The ID of the transit gateway peering attachment.
    Arn string
    Peering Amazon Resource Name (ARN).
    CoreNetworkArn string
    The ARN of the core network.
    EdgeLocation string
    The edge location for the peer.
    Id string
    The provider-assigned unique ID for this managed resource.
    OwnerAccountId string
    The ID of the account owner.
    PeeringType string
    The type of peering. This will be TRANSIT_GATEWAY.
    ResourceArn string
    The resource ARN of the peer.
    TagsAll map[string]string
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    TransitGatewayPeeringAttachmentId string
    The ID of the transit gateway peering attachment.
    arn String
    Peering Amazon Resource Name (ARN).
    coreNetworkArn String
    The ARN of the core network.
    edgeLocation String
    The edge location for the peer.
    id String
    The provider-assigned unique ID for this managed resource.
    ownerAccountId String
    The ID of the account owner.
    peeringType String
    The type of peering. This will be TRANSIT_GATEWAY.
    resourceArn String
    The resource ARN of the peer.
    tagsAll Map<String,String>
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transitGatewayPeeringAttachmentId String
    The ID of the transit gateway peering attachment.
    arn string
    Peering Amazon Resource Name (ARN).
    coreNetworkArn string
    The ARN of the core network.
    edgeLocation string
    The edge location for the peer.
    id string
    The provider-assigned unique ID for this managed resource.
    ownerAccountId string
    The ID of the account owner.
    peeringType string
    The type of peering. This will be TRANSIT_GATEWAY.
    resourceArn string
    The resource ARN of the peer.
    tagsAll {[key: string]: string}
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transitGatewayPeeringAttachmentId string
    The ID of the transit gateway peering attachment.
    arn str
    Peering Amazon Resource Name (ARN).
    core_network_arn str
    The ARN of the core network.
    edge_location str
    The edge location for the peer.
    id str
    The provider-assigned unique ID for this managed resource.
    owner_account_id str
    The ID of the account owner.
    peering_type str
    The type of peering. This will be TRANSIT_GATEWAY.
    resource_arn str
    The resource ARN of the peer.
    tags_all Mapping[str, str]
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transit_gateway_peering_attachment_id str
    The ID of the transit gateway peering attachment.
    arn String
    Peering Amazon Resource Name (ARN).
    coreNetworkArn String
    The ARN of the core network.
    edgeLocation String
    The edge location for the peer.
    id String
    The provider-assigned unique ID for this managed resource.
    ownerAccountId String
    The ID of the account owner.
    peeringType String
    The type of peering. This will be TRANSIT_GATEWAY.
    resourceArn String
    The resource ARN of the peer.
    tagsAll Map<String>
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transitGatewayPeeringAttachmentId String
    The ID of the transit gateway peering attachment.

    Look up Existing TransitGatewayPeering Resource

    Get an existing TransitGatewayPeering resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: TransitGatewayPeeringState, opts?: CustomResourceOptions): TransitGatewayPeering
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            arn: Optional[str] = None,
            core_network_arn: Optional[str] = None,
            core_network_id: Optional[str] = None,
            edge_location: Optional[str] = None,
            owner_account_id: Optional[str] = None,
            peering_type: Optional[str] = None,
            resource_arn: Optional[str] = None,
            tags: Optional[Mapping[str, str]] = None,
            tags_all: Optional[Mapping[str, str]] = None,
            transit_gateway_arn: Optional[str] = None,
            transit_gateway_peering_attachment_id: Optional[str] = None) -> TransitGatewayPeering
    func GetTransitGatewayPeering(ctx *Context, name string, id IDInput, state *TransitGatewayPeeringState, opts ...ResourceOption) (*TransitGatewayPeering, error)
    public static TransitGatewayPeering Get(string name, Input<string> id, TransitGatewayPeeringState? state, CustomResourceOptions? opts = null)
    public static TransitGatewayPeering get(String name, Output<String> id, TransitGatewayPeeringState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Arn string
    Peering Amazon Resource Name (ARN).
    CoreNetworkArn string
    The ARN of the core network.
    CoreNetworkId string
    The ID of a core network.
    EdgeLocation string
    The edge location for the peer.
    OwnerAccountId string
    The ID of the account owner.
    PeeringType string
    The type of peering. This will be TRANSIT_GATEWAY.
    ResourceArn string
    The resource ARN of the peer.
    Tags Dictionary<string, string>
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    TagsAll Dictionary<string, string>
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    TransitGatewayArn string
    The ARN of the transit gateway for the peering request.
    TransitGatewayPeeringAttachmentId string
    The ID of the transit gateway peering attachment.
    Arn string
    Peering Amazon Resource Name (ARN).
    CoreNetworkArn string
    The ARN of the core network.
    CoreNetworkId string
    The ID of a core network.
    EdgeLocation string
    The edge location for the peer.
    OwnerAccountId string
    The ID of the account owner.
    PeeringType string
    The type of peering. This will be TRANSIT_GATEWAY.
    ResourceArn string
    The resource ARN of the peer.
    Tags map[string]string
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    TagsAll map[string]string
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    TransitGatewayArn string
    The ARN of the transit gateway for the peering request.
    TransitGatewayPeeringAttachmentId string
    The ID of the transit gateway peering attachment.
    arn String
    Peering Amazon Resource Name (ARN).
    coreNetworkArn String
    The ARN of the core network.
    coreNetworkId String
    The ID of a core network.
    edgeLocation String
    The edge location for the peer.
    ownerAccountId String
    The ID of the account owner.
    peeringType String
    The type of peering. This will be TRANSIT_GATEWAY.
    resourceArn String
    The resource ARN of the peer.
    tags Map<String,String>
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    tagsAll Map<String,String>
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transitGatewayArn String
    The ARN of the transit gateway for the peering request.
    transitGatewayPeeringAttachmentId String
    The ID of the transit gateway peering attachment.
    arn string
    Peering Amazon Resource Name (ARN).
    coreNetworkArn string
    The ARN of the core network.
    coreNetworkId string
    The ID of a core network.
    edgeLocation string
    The edge location for the peer.
    ownerAccountId string
    The ID of the account owner.
    peeringType string
    The type of peering. This will be TRANSIT_GATEWAY.
    resourceArn string
    The resource ARN of the peer.
    tags {[key: string]: string}
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    tagsAll {[key: string]: string}
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transitGatewayArn string
    The ARN of the transit gateway for the peering request.
    transitGatewayPeeringAttachmentId string
    The ID of the transit gateway peering attachment.
    arn str
    Peering Amazon Resource Name (ARN).
    core_network_arn str
    The ARN of the core network.
    core_network_id str
    The ID of a core network.
    edge_location str
    The edge location for the peer.
    owner_account_id str
    The ID of the account owner.
    peering_type str
    The type of peering. This will be TRANSIT_GATEWAY.
    resource_arn str
    The resource ARN of the peer.
    tags Mapping[str, str]
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    tags_all Mapping[str, str]
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transit_gateway_arn str
    The ARN of the transit gateway for the peering request.
    transit_gateway_peering_attachment_id str
    The ID of the transit gateway peering attachment.
    arn String
    Peering Amazon Resource Name (ARN).
    coreNetworkArn String
    The ARN of the core network.
    coreNetworkId String
    The ID of a core network.
    edgeLocation String
    The edge location for the peer.
    ownerAccountId String
    The ID of the account owner.
    peeringType String
    The type of peering. This will be TRANSIT_GATEWAY.
    resourceArn String
    The resource ARN of the peer.
    tags Map<String>
    Key-value tags for the peering. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.
    tagsAll Map<String>
    A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

    Deprecated: Please use tags instead.

    transitGatewayArn String
    The ARN of the transit gateway for the peering request.
    transitGatewayPeeringAttachmentId String
    The ID of the transit gateway peering attachment.

    Import

    Using pulumi import, import aws_networkmanager_transit_gateway_peering using the peering ID. For example:

    $ pulumi import aws:networkmanager/transitGatewayPeering:TransitGatewayPeering example peering-444555aaabbb11223
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo
    AWS v6.55.0 published on Monday, Oct 7, 2024 by Pulumi