Class CfnTransitGatewayAttachment
Attaches a VPC to a transit gateway.
Implements
Inherited Members
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnTransitGatewayAttachment : CfnResource, IInspectable, ITransitGatewayAttachmentRef, IConstruct, IDependable, IEnvironmentAware, ITaggable
Syntax (vb)
Public Class CfnTransitGatewayAttachment Inherits CfnResource Implements IInspectable, ITransitGatewayAttachmentRef, IConstruct, IDependable, IEnvironmentAware, ITaggable
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.EC2;
var options;
var cfnTransitGatewayAttachment = new CfnTransitGatewayAttachment(this, "MyCfnTransitGatewayAttachment", new CfnTransitGatewayAttachmentProps {
SubnetIds = new [] { "subnetIds" },
TransitGatewayId = "transitGatewayId",
VpcId = "vpcId",
// the properties below are optional
Options = options,
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
});
Synopsis
Constructors
| CfnTransitGatewayAttachment(Construct, string, ICfnTransitGatewayAttachmentProps) | Create a new |
Properties
| AttrId | The ID of the attachment. |
| CFN_RESOURCE_TYPE_NAME | The CloudFormation resource type name for this resource class. |
| CfnProperties | Attaches a VPC to a transit gateway. |
| Options | The VPC attachment options. |
| SubnetIds | The IDs of one or more subnets. |
| Tags | Tag Manager which manages the tags for this resource. |
| TagsRaw | The tags for the attachment. |
| TransitGatewayAttachmentRef | A reference to a TransitGatewayAttachment resource. |
| TransitGatewayId | The ID of the transit gateway. |
| VpcId | The ID of the VPC. |
Methods
| ArnForTransitGatewayAttachment(ITransitGatewayAttachmentRef) | Attaches a VPC to a transit gateway. |
| FromTransitGatewayAttachmentId(Construct, string, string) | Creates a new ITransitGatewayAttachmentRef from a transitGatewayAttachmentId. |
| Inspect(TreeInspector) | Examines the CloudFormation resource and discloses attributes. |
| IsCfnTransitGatewayAttachment(object) | Checks whether the given object is a CfnTransitGatewayAttachment. |
| RenderProperties(IDictionary<string, object>) | Attaches a VPC to a transit gateway. |
Constructors
CfnTransitGatewayAttachment(Construct, string, ICfnTransitGatewayAttachmentProps)
Create a new AWS::EC2::TransitGatewayAttachment.
public CfnTransitGatewayAttachment(Construct scope, string id, ICfnTransitGatewayAttachmentProps props)
Parameters
- scope Construct
Scope in which this resource is defined.
- id string
Construct identifier for this resource (unique in its scope).
- props ICfnTransitGatewayAttachmentProps
Resource properties.
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Properties
AttrId
The ID of the attachment.
public virtual string AttrId { get; }
Property Value
Remarks
CloudformationAttribute: Id
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
public static string CFN_RESOURCE_TYPE_NAME { get; }
Property Value
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
CfnProperties
Attaches a VPC to a transit gateway.
protected override IDictionary<string, object> CfnProperties { get; }
Property Value
Overrides
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Options
The VPC attachment options.
public virtual object? Options { get; set; }
Property Value
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
SubnetIds
The IDs of one or more subnets.
public virtual string[] SubnetIds { get; set; }
Property Value
string[]
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Tags
Tag Manager which manages the tags for this resource.
public virtual TagManager Tags { get; }
Property Value
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
TagsRaw
The tags for the attachment.
public virtual ICfnTag[]? TagsRaw { get; set; }
Property Value
ICfnTag[]
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
TransitGatewayAttachmentRef
A reference to a TransitGatewayAttachment resource.
public virtual ITransitGatewayAttachmentReference TransitGatewayAttachmentRef { get; }
Property Value
ITransitGatewayAttachmentReference
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
TransitGatewayId
The ID of the transit gateway.
public virtual string TransitGatewayId { get; set; }
Property Value
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
VpcId
The ID of the VPC.
public virtual string VpcId { get; set; }
Property Value
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Methods
ArnForTransitGatewayAttachment(ITransitGatewayAttachmentRef)
Attaches a VPC to a transit gateway.
public static string ArnForTransitGatewayAttachment(ITransitGatewayAttachmentRef resource)
Parameters
- resource ITransitGatewayAttachmentRef
Returns
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.EC2;
var options;
var cfnTransitGatewayAttachment = new CfnTransitGatewayAttachment(this, "MyCfnTransitGatewayAttachment", new CfnTransitGatewayAttachmentProps {
SubnetIds = new [] { "subnetIds" },
TransitGatewayId = "transitGatewayId",
VpcId = "vpcId",
// the properties below are optional
Options = options,
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
});
FromTransitGatewayAttachmentId(Construct, string, string)
Creates a new ITransitGatewayAttachmentRef from a transitGatewayAttachmentId.
public static ITransitGatewayAttachmentRef FromTransitGatewayAttachmentId(Construct scope, string id, string transitGatewayAttachmentId)
Parameters
Returns
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Inspect(TreeInspector)
Examines the CloudFormation resource and discloses attributes.
public virtual void Inspect(TreeInspector inspector)
Parameters
- inspector TreeInspector
tree inspector to collect and process attributes.
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
IsCfnTransitGatewayAttachment(object)
Checks whether the given object is a CfnTransitGatewayAttachment.
public static bool IsCfnTransitGatewayAttachment(object x)
Parameters
- x object
Returns
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
RenderProperties(IDictionary<string, object>)
Attaches a VPC to a transit gateway.
protected override IDictionary<string, object> RenderProperties(IDictionary<string, object> props)
Parameters
- props IDictionary<string, object>
Returns
Overrides
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated