We recommend new projects start with resources from the AWS provider.
published on Wednesday, Nov 18, 2026 by Pulumi
We recommend new projects start with resources from the AWS provider.
published on Wednesday, Nov 18, 2026 by Pulumi
Resource Type definition for AWS::EC2::TransitGatewayAttachmentNatConfiguration. Configures static 1:1 NAT on a transit gateway attachment. Each rule translates a source CIDR to a NAT CIDR. NatGatewaySupport controls whether creating this resource activates the rules or stages them; deleting this resource disables NAT gateway support and removes all NAT rules. This resource must be managed from the account that owns the transit gateway. NAT support depends on the attachment type, and the transit gateway rejects a request to configure NAT on an attachment type that does not support it.
Create TransitGatewayAttachmentNatConfiguration Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new TransitGatewayAttachmentNatConfiguration(name: string, args: TransitGatewayAttachmentNatConfigurationArgs, opts?: CustomResourceOptions);@overload
def TransitGatewayAttachmentNatConfiguration(resource_name: str,
args: TransitGatewayAttachmentNatConfigurationArgs,
opts: Optional[ResourceOptions] = None)
@overload
def TransitGatewayAttachmentNatConfiguration(resource_name: str,
opts: Optional[ResourceOptions] = None,
nat_gateway_rules: Optional[Sequence[TransitGatewayAttachmentNatConfigurationNatRuleArgs]] = None,
nat_gateway_support: Optional[TransitGatewayAttachmentNatConfigurationNatGatewaySupport] = None,
transit_gateway_attachment_id: Optional[str] = None,
nat_system_route_support: Optional[TransitGatewayAttachmentNatConfigurationNatSystemRouteSupport] = None)func NewTransitGatewayAttachmentNatConfiguration(ctx *Context, name string, args TransitGatewayAttachmentNatConfigurationArgs, opts ...ResourceOption) (*TransitGatewayAttachmentNatConfiguration, error)public TransitGatewayAttachmentNatConfiguration(string name, TransitGatewayAttachmentNatConfigurationArgs args, CustomResourceOptions? opts = null)
public TransitGatewayAttachmentNatConfiguration(String name, TransitGatewayAttachmentNatConfigurationArgs args)
public TransitGatewayAttachmentNatConfiguration(String name, TransitGatewayAttachmentNatConfigurationArgs args, CustomResourceOptions options)
type: aws-native:ec2:TransitGatewayAttachmentNatConfiguration
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "aws-native_ec2_transit_gateway_attachment_nat_configuration" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args TransitGatewayAttachmentNatConfigurationArgs
- 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 TransitGatewayAttachmentNatConfigurationArgs
- 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 TransitGatewayAttachmentNatConfigurationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args TransitGatewayAttachmentNatConfigurationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args TransitGatewayAttachmentNatConfigurationArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
TransitGatewayAttachmentNatConfiguration Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The TransitGatewayAttachmentNatConfiguration resource accepts the following input properties:
- Nat
Gateway List<Pulumi.Rules Aws Native. Ec2. Inputs. Transit Gateway Attachment Nat Configuration Nat Rule> - The complete set of NAT rules for the attachment. Updating this property replaces the entire rule set: rules omitted from the new value are removed.
- Nat
Gateway Pulumi.Support Aws Native. Ec2. Transit Gateway Attachment Nat Configuration Nat Gateway Support - Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
- Transit
Gateway stringAttachment Id - The ID of the transit gateway attachment to configure NAT on.
- Nat
System Pulumi.Route Support Aws Native. Ec2. Transit Gateway Attachment Nat Configuration Nat System Route Support - Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
- Nat
Gateway []TransitRules Gateway Attachment Nat Configuration Nat Rule Args - The complete set of NAT rules for the attachment. Updating this property replaces the entire rule set: rules omitted from the new value are removed.
- Nat
Gateway TransitSupport Gateway Attachment Nat Configuration Nat Gateway Support - Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
- Transit
Gateway stringAttachment Id - The ID of the transit gateway attachment to configure NAT on.
- Nat
System TransitRoute Support Gateway Attachment Nat Configuration Nat System Route Support - Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
- nat_
gateway_ list(object)rules - The complete set of NAT rules for the attachment. Updating this property replaces the entire rule set: rules omitted from the new value are removed.
- nat_
gateway_ "enable" | "disable"support - Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
- transit_
gateway_ stringattachment_ id - The ID of the transit gateway attachment to configure NAT on.
- nat_
system_ "enable" | "disable"route_ support - Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
- nat
Gateway List<TransitRules Gateway Attachment Nat Configuration Nat Rule> - The complete set of NAT rules for the attachment. Updating this property replaces the entire rule set: rules omitted from the new value are removed.
- nat
Gateway TransitSupport Gateway Attachment Nat Configuration Nat Gateway Support - Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
- transit
Gateway StringAttachment Id - The ID of the transit gateway attachment to configure NAT on.
- nat
System TransitRoute Support Gateway Attachment Nat Configuration Nat System Route Support - Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
- nat
Gateway TransitRules Gateway Attachment Nat Configuration Nat Rule[] - The complete set of NAT rules for the attachment. Updating this property replaces the entire rule set: rules omitted from the new value are removed.
- nat
Gateway TransitSupport Gateway Attachment Nat Configuration Nat Gateway Support - Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
- transit
Gateway stringAttachment Id - The ID of the transit gateway attachment to configure NAT on.
- nat
System TransitRoute Support Gateway Attachment Nat Configuration Nat System Route Support - Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
- nat_
gateway_ Sequence[Transitrules Gateway Attachment Nat Configuration Nat Rule Args] - The complete set of NAT rules for the attachment. Updating this property replaces the entire rule set: rules omitted from the new value are removed.
- nat_
gateway_ Transitsupport Gateway Attachment Nat Configuration Nat Gateway Support - Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
- transit_
gateway_ strattachment_ id - The ID of the transit gateway attachment to configure NAT on.
- nat_
system_ Transitroute_ support Gateway Attachment Nat Configuration Nat System Route Support - Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
- nat
Gateway List<Property Map>Rules - The complete set of NAT rules for the attachment. Updating this property replaces the entire rule set: rules omitted from the new value are removed.
- nat
Gateway "enable" | "disable"Support - Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
- transit
Gateway StringAttachment Id - The ID of the transit gateway attachment to configure NAT on.
- nat
System "enable" | "disable"Route Support - Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
Outputs
All input properties are implicitly available as output properties. Additionally, the TransitGatewayAttachmentNatConfiguration resource produces the following output properties:
- Arn string
- Synthetic ARN encoding the NAT configuration's identity (the transit gateway attachment ID). Transit Gateway does not issue an ARN for a NAT configuration; this value exists so the configuration has a primary identifier, and it is not accepted by any EC2 API.
- Id string
- The provider-assigned unique ID for this managed resource.
- Arn string
- Synthetic ARN encoding the NAT configuration's identity (the transit gateway attachment ID). Transit Gateway does not issue an ARN for a NAT configuration; this value exists so the configuration has a primary identifier, and it is not accepted by any EC2 API.
- Id string
- The provider-assigned unique ID for this managed resource.
- arn string
- Synthetic ARN encoding the NAT configuration's identity (the transit gateway attachment ID). Transit Gateway does not issue an ARN for a NAT configuration; this value exists so the configuration has a primary identifier, and it is not accepted by any EC2 API.
- id string
- The provider-assigned unique ID for this managed resource.
- arn String
- Synthetic ARN encoding the NAT configuration's identity (the transit gateway attachment ID). Transit Gateway does not issue an ARN for a NAT configuration; this value exists so the configuration has a primary identifier, and it is not accepted by any EC2 API.
- id String
- The provider-assigned unique ID for this managed resource.
- arn string
- Synthetic ARN encoding the NAT configuration's identity (the transit gateway attachment ID). Transit Gateway does not issue an ARN for a NAT configuration; this value exists so the configuration has a primary identifier, and it is not accepted by any EC2 API.
- id string
- The provider-assigned unique ID for this managed resource.
- arn str
- Synthetic ARN encoding the NAT configuration's identity (the transit gateway attachment ID). Transit Gateway does not issue an ARN for a NAT configuration; this value exists so the configuration has a primary identifier, and it is not accepted by any EC2 API.
- id str
- The provider-assigned unique ID for this managed resource.
- arn String
- Synthetic ARN encoding the NAT configuration's identity (the transit gateway attachment ID). Transit Gateway does not issue an ARN for a NAT configuration; this value exists so the configuration has a primary identifier, and it is not accepted by any EC2 API.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing TransitGatewayAttachmentNatConfiguration Resource
Get an existing TransitGatewayAttachmentNatConfiguration 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>, opts?: CustomResourceOptions): TransitGatewayAttachmentNatConfiguration@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None) -> TransitGatewayAttachmentNatConfigurationfunc GetTransitGatewayAttachmentNatConfiguration(ctx *Context, name string, id IDInput, state *TransitGatewayAttachmentNatConfigurationState, opts ...ResourceOption) (*TransitGatewayAttachmentNatConfiguration, error)public static TransitGatewayAttachmentNatConfiguration Get(string name, Input<string> id, CustomResourceOptions? opts = null)public static TransitGatewayAttachmentNatConfiguration get(String name, Output<String> id, CustomResourceOptions options)resources: existingTransitGatewayAttachmentNatConfiguration: type: aws-native:ec2:TransitGatewayAttachmentNatConfiguration get: id: ${id}import {
to = aws-native_ec2_transit_gateway_attachment_nat_configuration.example
id = "${id}"
}
- name string
- The unique name of the resulting resource.
- id Input<ID>
- The unique provider ID of the resource to look up.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resulting resource.
- id str
- The unique provider ID of the resource to look up.
- 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 resulting resource.
- id IDInput
- The unique provider ID of the resource to look up.
- state TransitGatewayAttachmentNatConfigurationState
- Pass nil. This resource has no state arguments.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resulting resource.
- id Input<string>
- The unique provider ID of the resource to look up.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resulting resource.
- id Output<String>
- The unique provider ID of the resource to look up.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Supporting Types
TransitGatewayAttachmentNatConfigurationNatGatewaySupport
Whether NAT gateway support is enabled on the attachment. Set to disable to stage NAT rules without activating them; the rules are retained and become active when this is later set to enable.
| Name | Value |
|---|---|
| Enable | enable |
| Disable | disable |
| Name | Value |
|---|---|
| Transit | enable |
| Transit | disable |
| Value |
|---|
enable |
disable |
| Name | Value |
|---|---|
| Enable | enable |
| Disable | disable |
| Name | Value |
|---|---|
| Enable | enable |
| Disable | disable |
| Name | Value |
|---|---|
| ENABLE | enable |
| DISABLE | disable |
| Value |
|---|
enable |
disable |
TransitGatewayAttachmentNatConfigurationNatRule, TransitGatewayAttachmentNatConfigurationNatRuleArgs
A static 1:1 NAT rule. Traffic whose source address falls within MatchSourceCidr is translated to the corresponding address in NatCidr.
- Match
Source stringCidr - The source CIDR that the rule matches on.
- Nat
Cidr string - The CIDR that the matched source addresses are translated to.
- Rule
Number int - The rule number.
- Match
Source stringCidr - The source CIDR that the rule matches on.
- Nat
Cidr string - The CIDR that the matched source addresses are translated to.
- Rule
Number int - The rule number.
- match_
source_ stringcidr - The source CIDR that the rule matches on.
- nat_
cidr string - The CIDR that the matched source addresses are translated to.
- rule_
number number - The rule number.
- match
Source StringCidr - The source CIDR that the rule matches on.
- nat
Cidr String - The CIDR that the matched source addresses are translated to.
- rule
Number Integer - The rule number.
- match
Source stringCidr - The source CIDR that the rule matches on.
- nat
Cidr string - The CIDR that the matched source addresses are translated to.
- rule
Number number - The rule number.
- match_
source_ strcidr - The source CIDR that the rule matches on.
- nat_
cidr str - The CIDR that the matched source addresses are translated to.
- rule_
number int - The rule number.
- match
Source StringCidr - The source CIDR that the rule matches on.
- nat
Cidr String - The CIDR that the matched source addresses are translated to.
- rule
Number Number - The rule number.
TransitGatewayAttachmentNatConfigurationNatSystemRouteSupport
Whether routes for the NAT CIDRs are installed into the transit gateway route tables associated with the attachment. Whether this is configurable depends on the attachment; where the value is forced, supplying the opposite value is rejected. Omitting this property leaves the setting to the service: on a new configuration the service applies the attachment's default, but on an attachment where the value is configurable it keeps the value already in effect rather than reverting to that default. Removing this property from a template, or deleting this resource, therefore leaves the setting at its last value rather than restoring the default, and a resource later created on the same attachment without this property inherits that value.
| Name | Value |
|---|---|
| Enable | enable |
| Disable | disable |
| Name | Value |
|---|---|
| Transit | enable |
| Transit | disable |
| Value |
|---|
enable |
disable |
| Name | Value |
|---|---|
| Enable | enable |
| Disable | disable |
| Name | Value |
|---|---|
| Enable | enable |
| Disable | disable |
| Name | Value |
|---|---|
| ENABLE | enable |
| DISABLE | disable |
| Value |
|---|
enable |
disable |
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.
published on Wednesday, Nov 18, 2026 by Pulumi