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

We recommend using Azure Native.

Azure Classic v5.58.0 published on Saturday, Dec 2, 2023 by Pulumi

azure.network.RouteFilter

Explore with Pulumi AI

azure logo

We recommend using Azure Native.

Azure Classic v5.58.0 published on Saturday, Dec 2, 2023 by Pulumi

    Manages a Route Filter.

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Azure = Pulumi.Azure;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Azure.Network.RouteFilter("example", new()
        {
            Location = "East US",
            ResourceGroupName = "example",
            Rule = new Azure.Network.Inputs.RouteFilterRuleArgs
            {
                Access = "Allow",
                Communities = new[]
                {
                    "12076:52004",
                },
                Name = "rule",
                RuleType = "Community",
            },
        });
    
    });
    
    package main
    
    import (
    	"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 {
    		_, err := network.NewRouteFilter(ctx, "example", &network.RouteFilterArgs{
    			Location:          pulumi.String("East US"),
    			ResourceGroupName: pulumi.String("example"),
    			Rule: &network.RouteFilterRuleArgs{
    				Access: pulumi.String("Allow"),
    				Communities: pulumi.StringArray{
    					pulumi.String("12076:52004"),
    				},
    				Name:     pulumi.String("rule"),
    				RuleType: pulumi.String("Community"),
    			},
    		})
    		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.network.RouteFilter;
    import com.pulumi.azure.network.RouteFilterArgs;
    import com.pulumi.azure.network.inputs.RouteFilterRuleArgs;
    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 example = new RouteFilter("example", RouteFilterArgs.builder()        
                .location("East US")
                .resourceGroupName("example")
                .rule(RouteFilterRuleArgs.builder()
                    .access("Allow")
                    .communities("12076:52004")
                    .name("rule")
                    .ruleType("Community")
                    .build())
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_azure as azure
    
    example = azure.network.RouteFilter("example",
        location="East US",
        resource_group_name="example",
        rule=azure.network.RouteFilterRuleArgs(
            access="Allow",
            communities=["12076:52004"],
            name="rule",
            rule_type="Community",
        ))
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    
    const example = new azure.network.RouteFilter("example", {
        location: "East US",
        resourceGroupName: "example",
        rule: {
            access: "Allow",
            communities: ["12076:52004"],
            name: "rule",
            ruleType: "Community",
        },
    });
    
    resources:
      example:
        type: azure:network:RouteFilter
        properties:
          location: East US
          resourceGroupName: example
          rule:
            access: Allow
            communities:
              - 12076:52004
            name: rule
            ruleType: Community
    

    Create RouteFilter Resource

    new RouteFilter(name: string, args: RouteFilterArgs, opts?: CustomResourceOptions);
    @overload
    def RouteFilter(resource_name: str,
                    opts: Optional[ResourceOptions] = None,
                    location: Optional[str] = None,
                    name: Optional[str] = None,
                    resource_group_name: Optional[str] = None,
                    rule: Optional[RouteFilterRuleArgs] = None,
                    tags: Optional[Mapping[str, str]] = None)
    @overload
    def RouteFilter(resource_name: str,
                    args: RouteFilterArgs,
                    opts: Optional[ResourceOptions] = None)
    func NewRouteFilter(ctx *Context, name string, args RouteFilterArgs, opts ...ResourceOption) (*RouteFilter, error)
    public RouteFilter(string name, RouteFilterArgs args, CustomResourceOptions? opts = null)
    public RouteFilter(String name, RouteFilterArgs args)
    public RouteFilter(String name, RouteFilterArgs args, CustomResourceOptions options)
    
    type: azure:network:RouteFilter
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args RouteFilterArgs
    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 RouteFilterArgs
    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 RouteFilterArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args RouteFilterArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args RouteFilterArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

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

    ResourceGroupName string

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Location string

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Name string

    The Name which should be used for this Route Filter.

    Rule RouteFilterRule

    A rule block as defined below.

    Tags Dictionary<string, string>

    A mapping of tags which should be assigned to the Route Filter.

    ResourceGroupName string

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Location string

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Name string

    The Name which should be used for this Route Filter.

    Rule RouteFilterRuleArgs

    A rule block as defined below.

    Tags map[string]string

    A mapping of tags which should be assigned to the Route Filter.

    resourceGroupName String

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    location String

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name String

    The Name which should be used for this Route Filter.

    rule RouteFilterRule

    A rule block as defined below.

    tags Map<String,String>

    A mapping of tags which should be assigned to the Route Filter.

    resourceGroupName string

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    location string

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name string

    The Name which should be used for this Route Filter.

    rule RouteFilterRule

    A rule block as defined below.

    tags {[key: string]: string}

    A mapping of tags which should be assigned to the Route Filter.

    resource_group_name str

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    location str

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name str

    The Name which should be used for this Route Filter.

    rule RouteFilterRuleArgs

    A rule block as defined below.

    tags Mapping[str, str]

    A mapping of tags which should be assigned to the Route Filter.

    resourceGroupName String

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    location String

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name String

    The Name which should be used for this Route Filter.

    rule Property Map

    A rule block as defined below.

    tags Map<String>

    A mapping of tags which should be assigned to the Route Filter.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the RouteFilter 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 RouteFilter Resource

    Get an existing RouteFilter 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?: RouteFilterState, opts?: CustomResourceOptions): RouteFilter
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            location: Optional[str] = None,
            name: Optional[str] = None,
            resource_group_name: Optional[str] = None,
            rule: Optional[RouteFilterRuleArgs] = None,
            tags: Optional[Mapping[str, str]] = None) -> RouteFilter
    func GetRouteFilter(ctx *Context, name string, id IDInput, state *RouteFilterState, opts ...ResourceOption) (*RouteFilter, error)
    public static RouteFilter Get(string name, Input<string> id, RouteFilterState? state, CustomResourceOptions? opts = null)
    public static RouteFilter get(String name, Output<String> id, RouteFilterState 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:
    Location string

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Name string

    The Name which should be used for this Route Filter.

    ResourceGroupName string

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Rule RouteFilterRule

    A rule block as defined below.

    Tags Dictionary<string, string>

    A mapping of tags which should be assigned to the Route Filter.

    Location string

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Name string

    The Name which should be used for this Route Filter.

    ResourceGroupName string

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    Rule RouteFilterRuleArgs

    A rule block as defined below.

    Tags map[string]string

    A mapping of tags which should be assigned to the Route Filter.

    location String

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name String

    The Name which should be used for this Route Filter.

    resourceGroupName String

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    rule RouteFilterRule

    A rule block as defined below.

    tags Map<String,String>

    A mapping of tags which should be assigned to the Route Filter.

    location string

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name string

    The Name which should be used for this Route Filter.

    resourceGroupName string

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    rule RouteFilterRule

    A rule block as defined below.

    tags {[key: string]: string}

    A mapping of tags which should be assigned to the Route Filter.

    location str

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name str

    The Name which should be used for this Route Filter.

    resource_group_name str

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    rule RouteFilterRuleArgs

    A rule block as defined below.

    tags Mapping[str, str]

    A mapping of tags which should be assigned to the Route Filter.

    location String

    The Azure Region where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    name String

    The Name which should be used for this Route Filter.

    resourceGroupName String

    The name of the Resource Group where the Route Filter should exist. Changing this forces a new Route Filter to be created.

    rule Property Map

    A rule block as defined below.

    tags Map<String>

    A mapping of tags which should be assigned to the Route Filter.

    Supporting Types

    RouteFilterRule, RouteFilterRuleArgs

    Access string

    The access type of the rule. The only possible value is Allow.

    Communities List<string>

    The collection for bgp community values to filter on. e.g. ['12076:5010','12076:5020'].

    Name string

    The name of the route filter rule.

    RuleType string

    The rule type of the rule. The only possible value is Community.

    Access string

    The access type of the rule. The only possible value is Allow.

    Communities []string

    The collection for bgp community values to filter on. e.g. ['12076:5010','12076:5020'].

    Name string

    The name of the route filter rule.

    RuleType string

    The rule type of the rule. The only possible value is Community.

    access String

    The access type of the rule. The only possible value is Allow.

    communities List<String>

    The collection for bgp community values to filter on. e.g. ['12076:5010','12076:5020'].

    name String

    The name of the route filter rule.

    ruleType String

    The rule type of the rule. The only possible value is Community.

    access string

    The access type of the rule. The only possible value is Allow.

    communities string[]

    The collection for bgp community values to filter on. e.g. ['12076:5010','12076:5020'].

    name string

    The name of the route filter rule.

    ruleType string

    The rule type of the rule. The only possible value is Community.

    access str

    The access type of the rule. The only possible value is Allow.

    communities Sequence[str]

    The collection for bgp community values to filter on. e.g. ['12076:5010','12076:5020'].

    name str

    The name of the route filter rule.

    rule_type str

    The rule type of the rule. The only possible value is Community.

    access String

    The access type of the rule. The only possible value is Allow.

    communities List<String>

    The collection for bgp community values to filter on. e.g. ['12076:5010','12076:5020'].

    name String

    The name of the route filter rule.

    ruleType String

    The rule type of the rule. The only possible value is Community.

    Import

    Route Filters can be imported using the resource id, e.g.

     $ pulumi import azure:network/routeFilter:RouteFilter example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.Network/routeFilters/routeFilter1
    

    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.58.0 published on Saturday, Dec 2, 2023 by Pulumi