1. Packages
  2. Nsxt Provider
  3. API Docs
  4. PolicyNatRule
nsxt 3.8.1 published on Wednesday, Apr 30, 2025 by vmware

nsxt.PolicyNatRule

Explore with Pulumi AI

nsxt logo
nsxt 3.8.1 published on Wednesday, Apr 30, 2025 by vmware

    Create PolicyNatRule Resource

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

    Constructor syntax

    new PolicyNatRule(name: string, args: PolicyNatRuleArgs, opts?: CustomResourceOptions);
    @overload
    def PolicyNatRule(resource_name: str,
                      args: PolicyNatRuleArgs,
                      opts: Optional[ResourceOptions] = None)
    
    @overload
    def PolicyNatRule(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      display_name: Optional[str] = None,
                      action: Optional[str] = None,
                      gateway_path: Optional[str] = None,
                      policy_based_vpn_mode: Optional[str] = None,
                      rule_priority: Optional[float] = None,
                      enabled: Optional[bool] = None,
                      firewall_match: Optional[str] = None,
                      description: Optional[str] = None,
                      logging: Optional[bool] = None,
                      nsx_id: Optional[str] = None,
                      context: Optional[PolicyNatRuleContextArgs] = None,
                      policy_nat_rule_id: Optional[str] = None,
                      destination_networks: Optional[Sequence[str]] = None,
                      scopes: Optional[Sequence[str]] = None,
                      service: Optional[str] = None,
                      source_networks: Optional[Sequence[str]] = None,
                      tags: Optional[Sequence[PolicyNatRuleTagArgs]] = None,
                      translated_networks: Optional[Sequence[str]] = None,
                      translated_ports: Optional[str] = None,
                      type: Optional[str] = None)
    func NewPolicyNatRule(ctx *Context, name string, args PolicyNatRuleArgs, opts ...ResourceOption) (*PolicyNatRule, error)
    public PolicyNatRule(string name, PolicyNatRuleArgs args, CustomResourceOptions? opts = null)
    public PolicyNatRule(String name, PolicyNatRuleArgs args)
    public PolicyNatRule(String name, PolicyNatRuleArgs args, CustomResourceOptions options)
    
    type: nsxt:PolicyNatRule
    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 PolicyNatRuleArgs
    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 PolicyNatRuleArgs
    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 PolicyNatRuleArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args PolicyNatRuleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args PolicyNatRuleArgs
    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 policyNatRuleResource = new Nsxt.PolicyNatRule("policyNatRuleResource", new()
    {
        DisplayName = "string",
        Action = "string",
        GatewayPath = "string",
        PolicyBasedVpnMode = "string",
        RulePriority = 0,
        Enabled = false,
        FirewallMatch = "string",
        Description = "string",
        Logging = false,
        NsxId = "string",
        Context = new Nsxt.Inputs.PolicyNatRuleContextArgs
        {
            ProjectId = "string",
        },
        PolicyNatRuleId = "string",
        DestinationNetworks = new[]
        {
            "string",
        },
        Scopes = new[]
        {
            "string",
        },
        Service = "string",
        SourceNetworks = new[]
        {
            "string",
        },
        Tags = new[]
        {
            new Nsxt.Inputs.PolicyNatRuleTagArgs
            {
                Scope = "string",
                Tag = "string",
            },
        },
        TranslatedNetworks = new[]
        {
            "string",
        },
        TranslatedPorts = "string",
        Type = "string",
    });
    
    example, err := nsxt.NewPolicyNatRule(ctx, "policyNatRuleResource", &nsxt.PolicyNatRuleArgs{
    	DisplayName:        pulumi.String("string"),
    	Action:             pulumi.String("string"),
    	GatewayPath:        pulumi.String("string"),
    	PolicyBasedVpnMode: pulumi.String("string"),
    	RulePriority:       pulumi.Float64(0),
    	Enabled:            pulumi.Bool(false),
    	FirewallMatch:      pulumi.String("string"),
    	Description:        pulumi.String("string"),
    	Logging:            pulumi.Bool(false),
    	NsxId:              pulumi.String("string"),
    	Context: &nsxt.PolicyNatRuleContextArgs{
    		ProjectId: pulumi.String("string"),
    	},
    	PolicyNatRuleId: pulumi.String("string"),
    	DestinationNetworks: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Scopes: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Service: pulumi.String("string"),
    	SourceNetworks: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Tags: nsxt.PolicyNatRuleTagArray{
    		&nsxt.PolicyNatRuleTagArgs{
    			Scope: pulumi.String("string"),
    			Tag:   pulumi.String("string"),
    		},
    	},
    	TranslatedNetworks: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	TranslatedPorts: pulumi.String("string"),
    	Type:            pulumi.String("string"),
    })
    
    var policyNatRuleResource = new PolicyNatRule("policyNatRuleResource", PolicyNatRuleArgs.builder()
        .displayName("string")
        .action("string")
        .gatewayPath("string")
        .policyBasedVpnMode("string")
        .rulePriority(0)
        .enabled(false)
        .firewallMatch("string")
        .description("string")
        .logging(false)
        .nsxId("string")
        .context(PolicyNatRuleContextArgs.builder()
            .projectId("string")
            .build())
        .policyNatRuleId("string")
        .destinationNetworks("string")
        .scopes("string")
        .service("string")
        .sourceNetworks("string")
        .tags(PolicyNatRuleTagArgs.builder()
            .scope("string")
            .tag("string")
            .build())
        .translatedNetworks("string")
        .translatedPorts("string")
        .type("string")
        .build());
    
    policy_nat_rule_resource = nsxt.PolicyNatRule("policyNatRuleResource",
        display_name="string",
        action="string",
        gateway_path="string",
        policy_based_vpn_mode="string",
        rule_priority=0,
        enabled=False,
        firewall_match="string",
        description="string",
        logging=False,
        nsx_id="string",
        context={
            "project_id": "string",
        },
        policy_nat_rule_id="string",
        destination_networks=["string"],
        scopes=["string"],
        service="string",
        source_networks=["string"],
        tags=[{
            "scope": "string",
            "tag": "string",
        }],
        translated_networks=["string"],
        translated_ports="string",
        type="string")
    
    const policyNatRuleResource = new nsxt.PolicyNatRule("policyNatRuleResource", {
        displayName: "string",
        action: "string",
        gatewayPath: "string",
        policyBasedVpnMode: "string",
        rulePriority: 0,
        enabled: false,
        firewallMatch: "string",
        description: "string",
        logging: false,
        nsxId: "string",
        context: {
            projectId: "string",
        },
        policyNatRuleId: "string",
        destinationNetworks: ["string"],
        scopes: ["string"],
        service: "string",
        sourceNetworks: ["string"],
        tags: [{
            scope: "string",
            tag: "string",
        }],
        translatedNetworks: ["string"],
        translatedPorts: "string",
        type: "string",
    });
    
    type: nsxt:PolicyNatRule
    properties:
        action: string
        context:
            projectId: string
        description: string
        destinationNetworks:
            - string
        displayName: string
        enabled: false
        firewallMatch: string
        gatewayPath: string
        logging: false
        nsxId: string
        policyBasedVpnMode: string
        policyNatRuleId: string
        rulePriority: 0
        scopes:
            - string
        service: string
        sourceNetworks:
            - string
        tags:
            - scope: string
              tag: string
        translatedNetworks:
            - string
        translatedPorts: string
        type: string
    

    PolicyNatRule 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 PolicyNatRule resource accepts the following input properties:

    Action string
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    DisplayName string
    Display name of the resource.
    GatewayPath string
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    Context PolicyNatRuleContext
    The context which the object belongs to
    Description string
    Description of the resource.
    DestinationNetworks List<string>
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    Enabled bool
    Enable/disable the Rule. Defaults to true.
    FirewallMatch string
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    Logging bool
    Enable/disable rule logging. Defaults to false.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    PolicyBasedVpnMode string
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    PolicyNatRuleId string
    RulePriority double
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    Scopes List<string>
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    Service string
    Policy path of Service on which the NAT rule will be applied.
    SourceNetworks List<string>
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    Tags List<PolicyNatRuleTag>
    A list of scope + tag pairs to associate with this NAT Rule.
    TranslatedNetworks List<string>
    A list of translated network IP addresses or CIDR.
    TranslatedPorts string
    Port number or port range. For use with DNAT action only.
    Type string
    NAT Type
    Action string
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    DisplayName string
    Display name of the resource.
    GatewayPath string
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    Context PolicyNatRuleContextArgs
    The context which the object belongs to
    Description string
    Description of the resource.
    DestinationNetworks []string
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    Enabled bool
    Enable/disable the Rule. Defaults to true.
    FirewallMatch string
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    Logging bool
    Enable/disable rule logging. Defaults to false.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    PolicyBasedVpnMode string
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    PolicyNatRuleId string
    RulePriority float64
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    Scopes []string
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    Service string
    Policy path of Service on which the NAT rule will be applied.
    SourceNetworks []string
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    Tags []PolicyNatRuleTagArgs
    A list of scope + tag pairs to associate with this NAT Rule.
    TranslatedNetworks []string
    A list of translated network IP addresses or CIDR.
    TranslatedPorts string
    Port number or port range. For use with DNAT action only.
    Type string
    NAT Type
    action String
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    displayName String
    Display name of the resource.
    gatewayPath String
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    context PolicyNatRuleContext
    The context which the object belongs to
    description String
    Description of the resource.
    destinationNetworks List<String>
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    enabled Boolean
    Enable/disable the Rule. Defaults to true.
    firewallMatch String
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    logging Boolean
    Enable/disable rule logging. Defaults to false.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    policyBasedVpnMode String
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policyNatRuleId String
    rulePriority Double
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes List<String>
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service String
    Policy path of Service on which the NAT rule will be applied.
    sourceNetworks List<String>
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags List<PolicyNatRuleTag>
    A list of scope + tag pairs to associate with this NAT Rule.
    translatedNetworks List<String>
    A list of translated network IP addresses or CIDR.
    translatedPorts String
    Port number or port range. For use with DNAT action only.
    type String
    NAT Type
    action string
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    displayName string
    Display name of the resource.
    gatewayPath string
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    context PolicyNatRuleContext
    The context which the object belongs to
    description string
    Description of the resource.
    destinationNetworks string[]
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    enabled boolean
    Enable/disable the Rule. Defaults to true.
    firewallMatch string
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    logging boolean
    Enable/disable rule logging. Defaults to false.
    nsxId string
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    policyBasedVpnMode string
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policyNatRuleId string
    rulePriority number
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes string[]
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service string
    Policy path of Service on which the NAT rule will be applied.
    sourceNetworks string[]
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags PolicyNatRuleTag[]
    A list of scope + tag pairs to associate with this NAT Rule.
    translatedNetworks string[]
    A list of translated network IP addresses or CIDR.
    translatedPorts string
    Port number or port range. For use with DNAT action only.
    type string
    NAT Type
    action str
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    display_name str
    Display name of the resource.
    gateway_path str
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    context PolicyNatRuleContextArgs
    The context which the object belongs to
    description str
    Description of the resource.
    destination_networks Sequence[str]
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    enabled bool
    Enable/disable the Rule. Defaults to true.
    firewall_match str
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    logging bool
    Enable/disable rule logging. Defaults to false.
    nsx_id str
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    policy_based_vpn_mode str
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policy_nat_rule_id str
    rule_priority float
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes Sequence[str]
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service str
    Policy path of Service on which the NAT rule will be applied.
    source_networks Sequence[str]
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags Sequence[PolicyNatRuleTagArgs]
    A list of scope + tag pairs to associate with this NAT Rule.
    translated_networks Sequence[str]
    A list of translated network IP addresses or CIDR.
    translated_ports str
    Port number or port range. For use with DNAT action only.
    type str
    NAT Type
    action String
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    displayName String
    Display name of the resource.
    gatewayPath String
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    context Property Map
    The context which the object belongs to
    description String
    Description of the resource.
    destinationNetworks List<String>
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    enabled Boolean
    Enable/disable the Rule. Defaults to true.
    firewallMatch String
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    logging Boolean
    Enable/disable rule logging. Defaults to false.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    policyBasedVpnMode String
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policyNatRuleId String
    rulePriority Number
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes List<String>
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service String
    Policy path of Service on which the NAT rule will be applied.
    sourceNetworks List<String>
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags List<Property Map>
    A list of scope + tag pairs to associate with this NAT Rule.
    translatedNetworks List<String>
    A list of translated network IP addresses or CIDR.
    translatedPorts String
    Port number or port range. For use with DNAT action only.
    type String
    NAT Type

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Path string
    The NSX path of the policy resource.
    Revision double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    Id string
    The provider-assigned unique ID for this managed resource.
    Path string
    The NSX path of the policy resource.
    Revision float64
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id String
    The provider-assigned unique ID for this managed resource.
    path String
    The NSX path of the policy resource.
    revision Double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id string
    The provider-assigned unique ID for this managed resource.
    path string
    The NSX path of the policy resource.
    revision number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id str
    The provider-assigned unique ID for this managed resource.
    path str
    The NSX path of the policy resource.
    revision float
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    id String
    The provider-assigned unique ID for this managed resource.
    path String
    The NSX path of the policy resource.
    revision Number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.

    Look up Existing PolicyNatRule Resource

    Get an existing PolicyNatRule 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?: PolicyNatRuleState, opts?: CustomResourceOptions): PolicyNatRule
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            action: Optional[str] = None,
            context: Optional[PolicyNatRuleContextArgs] = None,
            description: Optional[str] = None,
            destination_networks: Optional[Sequence[str]] = None,
            display_name: Optional[str] = None,
            enabled: Optional[bool] = None,
            firewall_match: Optional[str] = None,
            gateway_path: Optional[str] = None,
            logging: Optional[bool] = None,
            nsx_id: Optional[str] = None,
            path: Optional[str] = None,
            policy_based_vpn_mode: Optional[str] = None,
            policy_nat_rule_id: Optional[str] = None,
            revision: Optional[float] = None,
            rule_priority: Optional[float] = None,
            scopes: Optional[Sequence[str]] = None,
            service: Optional[str] = None,
            source_networks: Optional[Sequence[str]] = None,
            tags: Optional[Sequence[PolicyNatRuleTagArgs]] = None,
            translated_networks: Optional[Sequence[str]] = None,
            translated_ports: Optional[str] = None,
            type: Optional[str] = None) -> PolicyNatRule
    func GetPolicyNatRule(ctx *Context, name string, id IDInput, state *PolicyNatRuleState, opts ...ResourceOption) (*PolicyNatRule, error)
    public static PolicyNatRule Get(string name, Input<string> id, PolicyNatRuleState? state, CustomResourceOptions? opts = null)
    public static PolicyNatRule get(String name, Output<String> id, PolicyNatRuleState state, CustomResourceOptions options)
    resources:  _:    type: nsxt:PolicyNatRule    get:      id: ${id}
    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:
    Action string
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    Context PolicyNatRuleContext
    The context which the object belongs to
    Description string
    Description of the resource.
    DestinationNetworks List<string>
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    DisplayName string
    Display name of the resource.
    Enabled bool
    Enable/disable the Rule. Defaults to true.
    FirewallMatch string
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    GatewayPath string
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    Logging bool
    Enable/disable rule logging. Defaults to false.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    Path string
    The NSX path of the policy resource.
    PolicyBasedVpnMode string
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    PolicyNatRuleId string
    Revision double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    RulePriority double
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    Scopes List<string>
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    Service string
    Policy path of Service on which the NAT rule will be applied.
    SourceNetworks List<string>
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    Tags List<PolicyNatRuleTag>
    A list of scope + tag pairs to associate with this NAT Rule.
    TranslatedNetworks List<string>
    A list of translated network IP addresses or CIDR.
    TranslatedPorts string
    Port number or port range. For use with DNAT action only.
    Type string
    NAT Type
    Action string
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    Context PolicyNatRuleContextArgs
    The context which the object belongs to
    Description string
    Description of the resource.
    DestinationNetworks []string
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    DisplayName string
    Display name of the resource.
    Enabled bool
    Enable/disable the Rule. Defaults to true.
    FirewallMatch string
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    GatewayPath string
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    Logging bool
    Enable/disable rule logging. Defaults to false.
    NsxId string
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    Path string
    The NSX path of the policy resource.
    PolicyBasedVpnMode string
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    PolicyNatRuleId string
    Revision float64
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    RulePriority float64
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    Scopes []string
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    Service string
    Policy path of Service on which the NAT rule will be applied.
    SourceNetworks []string
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    Tags []PolicyNatRuleTagArgs
    A list of scope + tag pairs to associate with this NAT Rule.
    TranslatedNetworks []string
    A list of translated network IP addresses or CIDR.
    TranslatedPorts string
    Port number or port range. For use with DNAT action only.
    Type string
    NAT Type
    action String
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    context PolicyNatRuleContext
    The context which the object belongs to
    description String
    Description of the resource.
    destinationNetworks List<String>
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    displayName String
    Display name of the resource.
    enabled Boolean
    Enable/disable the Rule. Defaults to true.
    firewallMatch String
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    gatewayPath String
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    logging Boolean
    Enable/disable rule logging. Defaults to false.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    path String
    The NSX path of the policy resource.
    policyBasedVpnMode String
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policyNatRuleId String
    revision Double
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    rulePriority Double
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes List<String>
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service String
    Policy path of Service on which the NAT rule will be applied.
    sourceNetworks List<String>
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags List<PolicyNatRuleTag>
    A list of scope + tag pairs to associate with this NAT Rule.
    translatedNetworks List<String>
    A list of translated network IP addresses or CIDR.
    translatedPorts String
    Port number or port range. For use with DNAT action only.
    type String
    NAT Type
    action string
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    context PolicyNatRuleContext
    The context which the object belongs to
    description string
    Description of the resource.
    destinationNetworks string[]
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    displayName string
    Display name of the resource.
    enabled boolean
    Enable/disable the Rule. Defaults to true.
    firewallMatch string
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    gatewayPath string
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    logging boolean
    Enable/disable rule logging. Defaults to false.
    nsxId string
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    path string
    The NSX path of the policy resource.
    policyBasedVpnMode string
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policyNatRuleId string
    revision number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    rulePriority number
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes string[]
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service string
    Policy path of Service on which the NAT rule will be applied.
    sourceNetworks string[]
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags PolicyNatRuleTag[]
    A list of scope + tag pairs to associate with this NAT Rule.
    translatedNetworks string[]
    A list of translated network IP addresses or CIDR.
    translatedPorts string
    Port number or port range. For use with DNAT action only.
    type string
    NAT Type
    action str
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    context PolicyNatRuleContextArgs
    The context which the object belongs to
    description str
    Description of the resource.
    destination_networks Sequence[str]
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    display_name str
    Display name of the resource.
    enabled bool
    Enable/disable the Rule. Defaults to true.
    firewall_match str
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    gateway_path str
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    logging bool
    Enable/disable rule logging. Defaults to false.
    nsx_id str
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    path str
    The NSX path of the policy resource.
    policy_based_vpn_mode str
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policy_nat_rule_id str
    revision float
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    rule_priority float
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes Sequence[str]
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service str
    Policy path of Service on which the NAT rule will be applied.
    source_networks Sequence[str]
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags Sequence[PolicyNatRuleTagArgs]
    A list of scope + tag pairs to associate with this NAT Rule.
    translated_networks Sequence[str]
    A list of translated network IP addresses or CIDR.
    translated_ports str
    Port number or port range. For use with DNAT action only.
    type str
    NAT Type
    action String
    The action for the NAT Rule. One of SNAT, DNAT, REFLEXIVE, NO_SNAT, NO_DNAT, NAT64.
    context Property Map
    The context which the object belongs to
    description String
    Description of the resource.
    destinationNetworks List<String>
    A list of destination network IP addresses or CIDR. If unspecified, the value will be ANY.
    displayName String
    Display name of the resource.
    enabled Boolean
    Enable/disable the Rule. Defaults to true.
    firewallMatch String
    Firewall match flag. One of MATCH_EXTERNAL_ADDRESS, MATCH_INTERNAL_ADDRESS, BYPASS.
    gatewayPath String
    The NSX Policy path to the Tier0 or Tier1 Gateway for this NAT Rule.
    logging Boolean
    Enable/disable rule logging. Defaults to false.
    nsxId String
    The NSX ID of this resource. If set, this ID will be used to create the policy resource.
    path String
    The NSX path of the policy resource.
    policyBasedVpnMode String
    Policy based VPN mode. One of BYPASS, MATCH. For use with DNAT and NO_DNAT actions only. Defaults to BYPASS when applicable. This argument is supported for NSX 4.0.0 and above.
    policyNatRuleId String
    revision Number
    Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
    rulePriority Number
    The priority of the rule. Valid values between 0 to 2147483647. Defaults to 100.
    scopes List<String>
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    service String
    Policy path of Service on which the NAT rule will be applied.
    sourceNetworks List<String>
    A list of source network IP addresses or CIDR. If unspecified, the value will be ANY.
    tags List<Property Map>
    A list of scope + tag pairs to associate with this NAT Rule.
    translatedNetworks List<String>
    A list of translated network IP addresses or CIDR.
    translatedPorts String
    Port number or port range. For use with DNAT action only.
    type String
    NAT Type

    Supporting Types

    PolicyNatRuleContext, PolicyNatRuleContextArgs

    ProjectId string
    The ID of the project which the object belongs to
    ProjectId string
    The ID of the project which the object belongs to
    projectId String
    The ID of the project which the object belongs to
    projectId string
    The ID of the project which the object belongs to
    project_id str
    The ID of the project which the object belongs to
    projectId String
    The ID of the project which the object belongs to

    PolicyNatRuleTag, PolicyNatRuleTagArgs

    Scope string
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    Tag string
    A list of scope + tag pairs to associate with this NAT Rule.
    Scope string
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    Tag string
    A list of scope + tag pairs to associate with this NAT Rule.
    scope String
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    tag String
    A list of scope + tag pairs to associate with this NAT Rule.
    scope string
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    tag string
    A list of scope + tag pairs to associate with this NAT Rule.
    scope str
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    tag str
    A list of scope + tag pairs to associate with this NAT Rule.
    scope String
    A list of paths to interfaces and/or labels where the NAT Rule is enforced.
    tag String
    A list of scope + tag pairs to associate with this NAT Rule.

    Package Details

    Repository
    nsxt vmware/terraform-provider-nsxt
    License
    Notes
    This Pulumi package is based on the nsxt Terraform Provider.
    nsxt logo
    nsxt 3.8.1 published on Wednesday, Apr 30, 2025 by vmware