Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
78 lines (60 sloc) 3.81 KB

AWS::EC2::TransitGatewayAttachment

Creates an attachment between a VPC and a transit gateway. For more information, see Amazon VPC Transit Gateways.

Topics

Syntax

To declare this entity in your AWS CloudFormation template, use the following syntax:

JSON

{
  "Type" : "AWS::EC2::TransitGatewayAttachment",
  "Properties" : {
    "[SubnetIds](#cfn-ec2-transitgatewayattachment-subnetids)" : [ String, ... ],
    "[Tags](#cfn-ec2-transitgatewayattachment-tags)" : [ [*Tag*](aws-properties-resource-tags.md), ... ],
    "[TransitGatewayId](#cfn-ec2-transitgatewayattachment-transitgatewayid)" : String,
    "[VpcId](#cfn-ec2-transitgatewayattachment-vpcid)" : String
  }
}

YAML

Type: "AWS::EC2::TransitGatewayAttachment"
Properties:
  [SubnetIds](#cfn-ec2-transitgatewayattachment-subnetids): 
    - String
  [Tags](#cfn-ec2-transitgatewayattachment-tags): 
    - [*Tag*](aws-properties-resource-tags.md)
  [TransitGatewayId](#cfn-ec2-transitgatewayattachment-transitgatewayid): String
  [VpcId](#cfn-ec2-transitgatewayattachment-vpcid): String

Properties

SubnetIds The IDs of one or more subnets. You can specify only one subnet per Availability Zone. You must specify at least one subnet, but we recommend that you specify two subnets for better availability. The transit gateway uses one IP address from each specified subnet.
Required: Yes
Type: List of String values
Update requires: Replacement

Tags The tags to apply to the VPC attachment.
Required: No
Type: List of Resource Tag property types
Update requires: Replacement

TransitGatewayId The ID of the transit gateway.
Required: Yes
Type: String
Update requires: Replacement

VpcId The ID of the VPC.
Required: Yes
Type: String
Update requires: Replacement

Return Values

Ref

When you pass the logical ID of an AWS::EC2::TransitGatewayAttachment resource to the intrinsic Ref function, the function returns the ID of the attachment, such as tgw-attach-vpc-0d39e0d39e0d39e.

For more information about using the Ref function, see Ref.

See Also

You can’t perform that action at this time.