1. Packages
  2. Azure Classic
  3. API Docs
  4. network
  5. FirewallNatRuleCollection

We recommend using Azure Native.

Azure Classic v5.56.0 published on Tuesday, Nov 21, 2023 by Pulumi

azure.network.FirewallNatRuleCollection

Explore with Pulumi AI

azure logo

We recommend using Azure Native.

Azure Classic v5.56.0 published on Tuesday, Nov 21, 2023 by Pulumi

    Manages a NAT Rule Collection within an Azure Firewall.

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Azure = Pulumi.Azure;
    
    return await Deployment.RunAsync(() => 
    {
        var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new()
        {
            Location = "West Europe",
        });
    
        var exampleVirtualNetwork = new Azure.Network.VirtualNetwork("exampleVirtualNetwork", new()
        {
            AddressSpaces = new[]
            {
                "10.0.0.0/16",
            },
            Location = exampleResourceGroup.Location,
            ResourceGroupName = exampleResourceGroup.Name,
        });
    
        var exampleSubnet = new Azure.Network.Subnet("exampleSubnet", new()
        {
            ResourceGroupName = exampleResourceGroup.Name,
            VirtualNetworkName = exampleVirtualNetwork.Name,
            AddressPrefixes = new[]
            {
                "10.0.1.0/24",
            },
        });
    
        var examplePublicIp = new Azure.Network.PublicIp("examplePublicIp", new()
        {
            Location = exampleResourceGroup.Location,
            ResourceGroupName = exampleResourceGroup.Name,
            AllocationMethod = "Static",
            Sku = "Standard",
        });
    
        var exampleFirewall = new Azure.Network.Firewall("exampleFirewall", new()
        {
            Location = exampleResourceGroup.Location,
            ResourceGroupName = exampleResourceGroup.Name,
            SkuName = "AZFW_VNet",
            SkuTier = "Standard",
            IpConfigurations = new[]
            {
                new Azure.Network.Inputs.FirewallIpConfigurationArgs
                {
                    Name = "configuration",
                    SubnetId = exampleSubnet.Id,
                    PublicIpAddressId = examplePublicIp.Id,
                },
            },
        });
    
        var exampleFirewallNatRuleCollection = new Azure.Network.FirewallNatRuleCollection("exampleFirewallNatRuleCollection", new()
        {
            AzureFirewallName = exampleFirewall.Name,
            ResourceGroupName = exampleResourceGroup.Name,
            Priority = 100,
            Action = "Dnat",
            Rules = new[]
            {
                new Azure.Network.Inputs.FirewallNatRuleCollectionRuleArgs
                {
                    Name = "testrule",
                    SourceAddresses = new[]
                    {
                        "10.0.0.0/16",
                    },
                    DestinationPorts = new[]
                    {
                        "53",
                    },
                    DestinationAddresses = new[]
                    {
                        examplePublicIp.IpAddress,
                    },
                    TranslatedPort = "53",
                    TranslatedAddress = "8.8.8.8",
                    Protocols = new[]
                    {
                        "TCP",
                        "UDP",
                    },
                },
            },
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
    	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/network"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
    			Location: pulumi.String("West Europe"),
    		})
    		if err != nil {
    			return err
    		}
    		exampleVirtualNetwork, err := network.NewVirtualNetwork(ctx, "exampleVirtualNetwork", &network.VirtualNetworkArgs{
    			AddressSpaces: pulumi.StringArray{
    				pulumi.String("10.0.0.0/16"),
    			},
    			Location:          exampleResourceGroup.Location,
    			ResourceGroupName: exampleResourceGroup.Name,
    		})
    		if err != nil {
    			return err
    		}
    		exampleSubnet, err := network.NewSubnet(ctx, "exampleSubnet", &network.SubnetArgs{
    			ResourceGroupName:  exampleResourceGroup.Name,
    			VirtualNetworkName: exampleVirtualNetwork.Name,
    			AddressPrefixes: pulumi.StringArray{
    				pulumi.String("10.0.1.0/24"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		examplePublicIp, err := network.NewPublicIp(ctx, "examplePublicIp", &network.PublicIpArgs{
    			Location:          exampleResourceGroup.Location,
    			ResourceGroupName: exampleResourceGroup.Name,
    			AllocationMethod:  pulumi.String("Static"),
    			Sku:               pulumi.String("Standard"),
    		})
    		if err != nil {
    			return err
    		}
    		exampleFirewall, err := network.NewFirewall(ctx, "exampleFirewall", &network.FirewallArgs{
    			Location:          exampleResourceGroup.Location,
    			ResourceGroupName: exampleResourceGroup.Name,
    			SkuName:           pulumi.String("AZFW_VNet"),
    			SkuTier:           pulumi.String("Standard"),
    			IpConfigurations: network.FirewallIpConfigurationArray{
    				&network.FirewallIpConfigurationArgs{
    					Name:              pulumi.String("configuration"),
    					SubnetId:          exampleSubnet.ID(),
    					PublicIpAddressId: examplePublicIp.ID(),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = network.NewFirewallNatRuleCollection(ctx, "exampleFirewallNatRuleCollection", &network.FirewallNatRuleCollectionArgs{
    			AzureFirewallName: exampleFirewall.Name,
    			ResourceGroupName: exampleResourceGroup.Name,
    			Priority:          pulumi.Int(100),
    			Action:            pulumi.String("Dnat"),
    			Rules: network.FirewallNatRuleCollectionRuleArray{
    				&network.FirewallNatRuleCollectionRuleArgs{
    					Name: pulumi.String("testrule"),
    					SourceAddresses: pulumi.StringArray{
    						pulumi.String("10.0.0.0/16"),
    					},
    					DestinationPorts: pulumi.StringArray{
    						pulumi.String("53"),
    					},
    					DestinationAddresses: pulumi.StringArray{
    						examplePublicIp.IpAddress,
    					},
    					TranslatedPort:    pulumi.String("53"),
    					TranslatedAddress: pulumi.String("8.8.8.8"),
    					Protocols: pulumi.StringArray{
    						pulumi.String("TCP"),
    						pulumi.String("UDP"),
    					},
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azure.core.ResourceGroup;
    import com.pulumi.azure.core.ResourceGroupArgs;
    import com.pulumi.azure.network.VirtualNetwork;
    import com.pulumi.azure.network.VirtualNetworkArgs;
    import com.pulumi.azure.network.Subnet;
    import com.pulumi.azure.network.SubnetArgs;
    import com.pulumi.azure.network.PublicIp;
    import com.pulumi.azure.network.PublicIpArgs;
    import com.pulumi.azure.network.Firewall;
    import com.pulumi.azure.network.FirewallArgs;
    import com.pulumi.azure.network.inputs.FirewallIpConfigurationArgs;
    import com.pulumi.azure.network.FirewallNatRuleCollection;
    import com.pulumi.azure.network.FirewallNatRuleCollectionArgs;
    import com.pulumi.azure.network.inputs.FirewallNatRuleCollectionRuleArgs;
    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 exampleResourceGroup = new ResourceGroup("exampleResourceGroup", ResourceGroupArgs.builder()        
                .location("West Europe")
                .build());
    
            var exampleVirtualNetwork = new VirtualNetwork("exampleVirtualNetwork", VirtualNetworkArgs.builder()        
                .addressSpaces("10.0.0.0/16")
                .location(exampleResourceGroup.location())
                .resourceGroupName(exampleResourceGroup.name())
                .build());
    
            var exampleSubnet = new Subnet("exampleSubnet", SubnetArgs.builder()        
                .resourceGroupName(exampleResourceGroup.name())
                .virtualNetworkName(exampleVirtualNetwork.name())
                .addressPrefixes("10.0.1.0/24")
                .build());
    
            var examplePublicIp = new PublicIp("examplePublicIp", PublicIpArgs.builder()        
                .location(exampleResourceGroup.location())
                .resourceGroupName(exampleResourceGroup.name())
                .allocationMethod("Static")
                .sku("Standard")
                .build());
    
            var exampleFirewall = new Firewall("exampleFirewall", FirewallArgs.builder()        
                .location(exampleResourceGroup.location())
                .resourceGroupName(exampleResourceGroup.name())
                .skuName("AZFW_VNet")
                .skuTier("Standard")
                .ipConfigurations(FirewallIpConfigurationArgs.builder()
                    .name("configuration")
                    .subnetId(exampleSubnet.id())
                    .publicIpAddressId(examplePublicIp.id())
                    .build())
                .build());
    
            var exampleFirewallNatRuleCollection = new FirewallNatRuleCollection("exampleFirewallNatRuleCollection", FirewallNatRuleCollectionArgs.builder()        
                .azureFirewallName(exampleFirewall.name())
                .resourceGroupName(exampleResourceGroup.name())
                .priority(100)
                .action("Dnat")
                .rules(FirewallNatRuleCollectionRuleArgs.builder()
                    .name("testrule")
                    .sourceAddresses("10.0.0.0/16")
                    .destinationPorts("53")
                    .destinationAddresses(examplePublicIp.ipAddress())
                    .translatedPort(53)
                    .translatedAddress("8.8.8.8")
                    .protocols(                
                        "TCP",
                        "UDP")
                    .build())
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_azure as azure
    
    example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe")
    example_virtual_network = azure.network.VirtualNetwork("exampleVirtualNetwork",
        address_spaces=["10.0.0.0/16"],
        location=example_resource_group.location,
        resource_group_name=example_resource_group.name)
    example_subnet = azure.network.Subnet("exampleSubnet",
        resource_group_name=example_resource_group.name,
        virtual_network_name=example_virtual_network.name,
        address_prefixes=["10.0.1.0/24"])
    example_public_ip = azure.network.PublicIp("examplePublicIp",
        location=example_resource_group.location,
        resource_group_name=example_resource_group.name,
        allocation_method="Static",
        sku="Standard")
    example_firewall = azure.network.Firewall("exampleFirewall",
        location=example_resource_group.location,
        resource_group_name=example_resource_group.name,
        sku_name="AZFW_VNet",
        sku_tier="Standard",
        ip_configurations=[azure.network.FirewallIpConfigurationArgs(
            name="configuration",
            subnet_id=example_subnet.id,
            public_ip_address_id=example_public_ip.id,
        )])
    example_firewall_nat_rule_collection = azure.network.FirewallNatRuleCollection("exampleFirewallNatRuleCollection",
        azure_firewall_name=example_firewall.name,
        resource_group_name=example_resource_group.name,
        priority=100,
        action="Dnat",
        rules=[azure.network.FirewallNatRuleCollectionRuleArgs(
            name="testrule",
            source_addresses=["10.0.0.0/16"],
            destination_ports=["53"],
            destination_addresses=[example_public_ip.ip_address],
            translated_port="53",
            translated_address="8.8.8.8",
            protocols=[
                "TCP",
                "UDP",
            ],
        )])
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    
    const exampleResourceGroup = new azure.core.ResourceGroup("exampleResourceGroup", {location: "West Europe"});
    const exampleVirtualNetwork = new azure.network.VirtualNetwork("exampleVirtualNetwork", {
        addressSpaces: ["10.0.0.0/16"],
        location: exampleResourceGroup.location,
        resourceGroupName: exampleResourceGroup.name,
    });
    const exampleSubnet = new azure.network.Subnet("exampleSubnet", {
        resourceGroupName: exampleResourceGroup.name,
        virtualNetworkName: exampleVirtualNetwork.name,
        addressPrefixes: ["10.0.1.0/24"],
    });
    const examplePublicIp = new azure.network.PublicIp("examplePublicIp", {
        location: exampleResourceGroup.location,
        resourceGroupName: exampleResourceGroup.name,
        allocationMethod: "Static",
        sku: "Standard",
    });
    const exampleFirewall = new azure.network.Firewall("exampleFirewall", {
        location: exampleResourceGroup.location,
        resourceGroupName: exampleResourceGroup.name,
        skuName: "AZFW_VNet",
        skuTier: "Standard",
        ipConfigurations: [{
            name: "configuration",
            subnetId: exampleSubnet.id,
            publicIpAddressId: examplePublicIp.id,
        }],
    });
    const exampleFirewallNatRuleCollection = new azure.network.FirewallNatRuleCollection("exampleFirewallNatRuleCollection", {
        azureFirewallName: exampleFirewall.name,
        resourceGroupName: exampleResourceGroup.name,
        priority: 100,
        action: "Dnat",
        rules: [{
            name: "testrule",
            sourceAddresses: ["10.0.0.0/16"],
            destinationPorts: ["53"],
            destinationAddresses: [examplePublicIp.ipAddress],
            translatedPort: "53",
            translatedAddress: "8.8.8.8",
            protocols: [
                "TCP",
                "UDP",
            ],
        }],
    });
    
    resources:
      exampleResourceGroup:
        type: azure:core:ResourceGroup
        properties:
          location: West Europe
      exampleVirtualNetwork:
        type: azure:network:VirtualNetwork
        properties:
          addressSpaces:
            - 10.0.0.0/16
          location: ${exampleResourceGroup.location}
          resourceGroupName: ${exampleResourceGroup.name}
      exampleSubnet:
        type: azure:network:Subnet
        properties:
          resourceGroupName: ${exampleResourceGroup.name}
          virtualNetworkName: ${exampleVirtualNetwork.name}
          addressPrefixes:
            - 10.0.1.0/24
      examplePublicIp:
        type: azure:network:PublicIp
        properties:
          location: ${exampleResourceGroup.location}
          resourceGroupName: ${exampleResourceGroup.name}
          allocationMethod: Static
          sku: Standard
      exampleFirewall:
        type: azure:network:Firewall
        properties:
          location: ${exampleResourceGroup.location}
          resourceGroupName: ${exampleResourceGroup.name}
          skuName: AZFW_VNet
          skuTier: Standard
          ipConfigurations:
            - name: configuration
              subnetId: ${exampleSubnet.id}
              publicIpAddressId: ${examplePublicIp.id}
      exampleFirewallNatRuleCollection:
        type: azure:network:FirewallNatRuleCollection
        properties:
          azureFirewallName: ${exampleFirewall.name}
          resourceGroupName: ${exampleResourceGroup.name}
          priority: 100
          action: Dnat
          rules:
            - name: testrule
              sourceAddresses:
                - 10.0.0.0/16
              destinationPorts:
                - '53'
              destinationAddresses:
                - ${examplePublicIp.ipAddress}
              translatedPort: 53
              translatedAddress: 8.8.8.8
              protocols:
                - TCP
                - UDP
    

    Create FirewallNatRuleCollection Resource

    new FirewallNatRuleCollection(name: string, args: FirewallNatRuleCollectionArgs, opts?: CustomResourceOptions);
    @overload
    def FirewallNatRuleCollection(resource_name: str,
                                  opts: Optional[ResourceOptions] = None,
                                  action: Optional[str] = None,
                                  azure_firewall_name: Optional[str] = None,
                                  name: Optional[str] = None,
                                  priority: Optional[int] = None,
                                  resource_group_name: Optional[str] = None,
                                  rules: Optional[Sequence[FirewallNatRuleCollectionRuleArgs]] = None)
    @overload
    def FirewallNatRuleCollection(resource_name: str,
                                  args: FirewallNatRuleCollectionArgs,
                                  opts: Optional[ResourceOptions] = None)
    func NewFirewallNatRuleCollection(ctx *Context, name string, args FirewallNatRuleCollectionArgs, opts ...ResourceOption) (*FirewallNatRuleCollection, error)
    public FirewallNatRuleCollection(string name, FirewallNatRuleCollectionArgs args, CustomResourceOptions? opts = null)
    public FirewallNatRuleCollection(String name, FirewallNatRuleCollectionArgs args)
    public FirewallNatRuleCollection(String name, FirewallNatRuleCollectionArgs args, CustomResourceOptions options)
    
    type: azure:network:FirewallNatRuleCollection
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args FirewallNatRuleCollectionArgs
    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 FirewallNatRuleCollectionArgs
    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 FirewallNatRuleCollectionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args FirewallNatRuleCollectionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args FirewallNatRuleCollectionArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

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

    Action string

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    AzureFirewallName string

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    Priority int

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    ResourceGroupName string

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    Rules List<FirewallNatRuleCollectionRule>

    One or more rule blocks as defined below.

    Name string

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    Action string

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    AzureFirewallName string

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    Priority int

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    ResourceGroupName string

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    Rules []FirewallNatRuleCollectionRuleArgs

    One or more rule blocks as defined below.

    Name string

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    action String

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azureFirewallName String

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    priority Integer

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resourceGroupName String

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules List<FirewallNatRuleCollectionRule>

    One or more rule blocks as defined below.

    name String

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    action string

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azureFirewallName string

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    priority number

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resourceGroupName string

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules FirewallNatRuleCollectionRule[]

    One or more rule blocks as defined below.

    name string

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    action str

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azure_firewall_name str

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    priority int

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resource_group_name str

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules Sequence[FirewallNatRuleCollectionRuleArgs]

    One or more rule blocks as defined below.

    name str

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    action String

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azureFirewallName String

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    priority Number

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resourceGroupName String

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules List<Property Map>

    One or more rule blocks as defined below.

    name String

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    Outputs

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

    Id string

    The provider-assigned unique ID for this managed resource.

    Id string

    The provider-assigned unique ID for this managed resource.

    id String

    The provider-assigned unique ID for this managed resource.

    id string

    The provider-assigned unique ID for this managed resource.

    id str

    The provider-assigned unique ID for this managed resource.

    id String

    The provider-assigned unique ID for this managed resource.

    Look up Existing FirewallNatRuleCollection Resource

    Get an existing FirewallNatRuleCollection 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?: FirewallNatRuleCollectionState, opts?: CustomResourceOptions): FirewallNatRuleCollection
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            action: Optional[str] = None,
            azure_firewall_name: Optional[str] = None,
            name: Optional[str] = None,
            priority: Optional[int] = None,
            resource_group_name: Optional[str] = None,
            rules: Optional[Sequence[FirewallNatRuleCollectionRuleArgs]] = None) -> FirewallNatRuleCollection
    func GetFirewallNatRuleCollection(ctx *Context, name string, id IDInput, state *FirewallNatRuleCollectionState, opts ...ResourceOption) (*FirewallNatRuleCollection, error)
    public static FirewallNatRuleCollection Get(string name, Input<string> id, FirewallNatRuleCollectionState? state, CustomResourceOptions? opts = null)
    public static FirewallNatRuleCollection get(String name, Output<String> id, FirewallNatRuleCollectionState 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:
    Action string

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    AzureFirewallName string

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    Name string

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    Priority int

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    ResourceGroupName string

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    Rules List<FirewallNatRuleCollectionRule>

    One or more rule blocks as defined below.

    Action string

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    AzureFirewallName string

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    Name string

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    Priority int

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    ResourceGroupName string

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    Rules []FirewallNatRuleCollectionRuleArgs

    One or more rule blocks as defined below.

    action String

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azureFirewallName String

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    name String

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    priority Integer

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resourceGroupName String

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules List<FirewallNatRuleCollectionRule>

    One or more rule blocks as defined below.

    action string

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azureFirewallName string

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    name string

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    priority number

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resourceGroupName string

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules FirewallNatRuleCollectionRule[]

    One or more rule blocks as defined below.

    action str

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azure_firewall_name str

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    name str

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    priority int

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resource_group_name str

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules Sequence[FirewallNatRuleCollectionRuleArgs]

    One or more rule blocks as defined below.

    action String

    Specifies the action the rule will apply to matching traffic. Possible values are Dnat and Snat.

    azureFirewallName String

    Specifies the name of the Firewall in which the NAT Rule Collection should be created. Changing this forces a new resource to be created.

    name String

    Specifies the name of the NAT Rule Collection which must be unique within the Firewall. Changing this forces a new resource to be created.

    priority Number

    Specifies the priority of the rule collection. Possible values are between 100 - 65000.

    resourceGroupName String

    Specifies the name of the Resource Group in which the Firewall exists. Changing this forces a new resource to be created.

    rules List<Property Map>

    One or more rule blocks as defined below.

    Supporting Types

    FirewallNatRuleCollectionRule, FirewallNatRuleCollectionRuleArgs

    DestinationAddresses List<string>

    A list of destination IP addresses and/or IP ranges.

    DestinationPorts List<string>

    A list of destination ports.

    Name string

    Specifies the name of the rule.

    Protocols List<string>

    A list of protocols. Possible values are Any, ICMP, TCP and UDP. If action is Dnat, protocols can only be TCP and UDP.

    TranslatedAddress string

    The address of the service behind the Firewall.

    TranslatedPort string

    The port of the service behind the Firewall.

    Description string

    Specifies a description for the rule.

    SourceAddresses List<string>

    A list of source IP addresses and/or IP ranges.

    SourceIpGroups List<string>

    A list of source IP Group IDs for the rule.

    NOTE At least one of source_addresses and source_ip_groups must be specified for a rule.

    DestinationAddresses []string

    A list of destination IP addresses and/or IP ranges.

    DestinationPorts []string

    A list of destination ports.

    Name string

    Specifies the name of the rule.

    Protocols []string

    A list of protocols. Possible values are Any, ICMP, TCP and UDP. If action is Dnat, protocols can only be TCP and UDP.

    TranslatedAddress string

    The address of the service behind the Firewall.

    TranslatedPort string

    The port of the service behind the Firewall.

    Description string

    Specifies a description for the rule.

    SourceAddresses []string

    A list of source IP addresses and/or IP ranges.

    SourceIpGroups []string

    A list of source IP Group IDs for the rule.

    NOTE At least one of source_addresses and source_ip_groups must be specified for a rule.

    destinationAddresses List<String>

    A list of destination IP addresses and/or IP ranges.

    destinationPorts List<String>

    A list of destination ports.

    name String

    Specifies the name of the rule.

    protocols List<String>

    A list of protocols. Possible values are Any, ICMP, TCP and UDP. If action is Dnat, protocols can only be TCP and UDP.

    translatedAddress String

    The address of the service behind the Firewall.

    translatedPort String

    The port of the service behind the Firewall.

    description String

    Specifies a description for the rule.

    sourceAddresses List<String>

    A list of source IP addresses and/or IP ranges.

    sourceIpGroups List<String>

    A list of source IP Group IDs for the rule.

    NOTE At least one of source_addresses and source_ip_groups must be specified for a rule.

    destinationAddresses string[]

    A list of destination IP addresses and/or IP ranges.

    destinationPorts string[]

    A list of destination ports.

    name string

    Specifies the name of the rule.

    protocols string[]

    A list of protocols. Possible values are Any, ICMP, TCP and UDP. If action is Dnat, protocols can only be TCP and UDP.

    translatedAddress string

    The address of the service behind the Firewall.

    translatedPort string

    The port of the service behind the Firewall.

    description string

    Specifies a description for the rule.

    sourceAddresses string[]

    A list of source IP addresses and/or IP ranges.

    sourceIpGroups string[]

    A list of source IP Group IDs for the rule.

    NOTE At least one of source_addresses and source_ip_groups must be specified for a rule.

    destination_addresses Sequence[str]

    A list of destination IP addresses and/or IP ranges.

    destination_ports Sequence[str]

    A list of destination ports.

    name str

    Specifies the name of the rule.

    protocols Sequence[str]

    A list of protocols. Possible values are Any, ICMP, TCP and UDP. If action is Dnat, protocols can only be TCP and UDP.

    translated_address str

    The address of the service behind the Firewall.

    translated_port str

    The port of the service behind the Firewall.

    description str

    Specifies a description for the rule.

    source_addresses Sequence[str]

    A list of source IP addresses and/or IP ranges.

    source_ip_groups Sequence[str]

    A list of source IP Group IDs for the rule.

    NOTE At least one of source_addresses and source_ip_groups must be specified for a rule.

    destinationAddresses List<String>

    A list of destination IP addresses and/or IP ranges.

    destinationPorts List<String>

    A list of destination ports.

    name String

    Specifies the name of the rule.

    protocols List<String>

    A list of protocols. Possible values are Any, ICMP, TCP and UDP. If action is Dnat, protocols can only be TCP and UDP.

    translatedAddress String

    The address of the service behind the Firewall.

    translatedPort String

    The port of the service behind the Firewall.

    description String

    Specifies a description for the rule.

    sourceAddresses List<String>

    A list of source IP addresses and/or IP ranges.

    sourceIpGroups List<String>

    A list of source IP Group IDs for the rule.

    NOTE At least one of source_addresses and source_ip_groups must be specified for a rule.

    Import

    Azure Firewall NAT Rule Collections can be imported using the resource id, e.g.

     $ pulumi import azure:network/firewallNatRuleCollection:FirewallNatRuleCollection example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Network/azureFirewalls/myfirewall/natRuleCollections/mycollection
    

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes

    This Pulumi package is based on the azurerm Terraform Provider.

    azure logo

    We recommend using Azure Native.

    Azure Classic v5.56.0 published on Tuesday, Nov 21, 2023 by Pulumi