1. Packages
  2. Ec Provider
  3. API Docs
  4. DeploymentTrafficFilter
ElasticCloud (EC) v0.10.2 published on Wednesday, Oct 2, 2024 by Pulumi

ec.DeploymentTrafficFilter

Explore with Pulumi AI

ec logo
ElasticCloud (EC) v0.10.2 published on Wednesday, Oct 2, 2024 by Pulumi

    Example Usage

    IP based traffic filter

    import * as pulumi from "@pulumi/pulumi";
    import * as ec from "@pulumi/ec";
    
    const latest = ec.getStack({
        versionRegex: "latest",
        region: "us-east-1",
    });
    const example = new ec.DeploymentTrafficFilter("example", {
        name: "my traffic filter name",
        region: "us-east-1",
        type: "ip",
        rules: [{
            source: "0.0.0.0/0",
        }],
    });
    // Create an Elastic Cloud deployment
    const exampleMinimal = new ec.Deployment("example_minimal", {
        name: "my_example_deployment",
        region: "us-east-1",
        version: latest.then(latest => latest.version),
        deploymentTemplateId: "aws-io-optimized-v2",
        trafficFilters: [example.id],
        elasticsearch: {
            hot: {
                autoscaling: {},
            },
        },
        kibana: {},
    });
    
    import pulumi
    import pulumi_ec as ec
    
    latest = ec.get_stack(version_regex="latest",
        region="us-east-1")
    example = ec.DeploymentTrafficFilter("example",
        name="my traffic filter name",
        region="us-east-1",
        type="ip",
        rules=[{
            "source": "0.0.0.0/0",
        }])
    # Create an Elastic Cloud deployment
    example_minimal = ec.Deployment("example_minimal",
        name="my_example_deployment",
        region="us-east-1",
        version=latest.version,
        deployment_template_id="aws-io-optimized-v2",
        traffic_filters=[example.id],
        elasticsearch={
            "hot": {
                "autoscaling": {},
            },
        },
        kibana={})
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-ec/sdk/go/ec"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		latest, err := ec.GetStack(ctx, &ec.GetStackArgs{
    			VersionRegex: "latest",
    			Region:       "us-east-1",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		example, err := ec.NewDeploymentTrafficFilter(ctx, "example", &ec.DeploymentTrafficFilterArgs{
    			Name:   pulumi.String("my traffic filter name"),
    			Region: pulumi.String("us-east-1"),
    			Type:   pulumi.String("ip"),
    			Rules: ec.DeploymentTrafficFilterRuleArray{
    				&ec.DeploymentTrafficFilterRuleArgs{
    					Source: pulumi.String("0.0.0.0/0"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		// Create an Elastic Cloud deployment
    		_, err = ec.NewDeployment(ctx, "example_minimal", &ec.DeploymentArgs{
    			Name:                 pulumi.String("my_example_deployment"),
    			Region:               pulumi.String("us-east-1"),
    			Version:              pulumi.String(latest.Version),
    			DeploymentTemplateId: pulumi.String("aws-io-optimized-v2"),
    			TrafficFilters: pulumi.StringArray{
    				example.ID(),
    			},
    			Elasticsearch: &ec.DeploymentElasticsearchArgs{
    				Hot: &ec.DeploymentElasticsearchHotArgs{
    					Autoscaling: nil,
    				},
    			},
    			Kibana: nil,
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using ElasticCloud = Pulumi.ElasticCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var latest = ElasticCloud.GetStack.Invoke(new()
        {
            VersionRegex = "latest",
            Region = "us-east-1",
        });
    
        var example = new ElasticCloud.DeploymentTrafficFilter("example", new()
        {
            Name = "my traffic filter name",
            Region = "us-east-1",
            Type = "ip",
            Rules = new[]
            {
                new ElasticCloud.Inputs.DeploymentTrafficFilterRuleArgs
                {
                    Source = "0.0.0.0/0",
                },
            },
        });
    
        // Create an Elastic Cloud deployment
        var exampleMinimal = new ElasticCloud.Deployment("example_minimal", new()
        {
            Name = "my_example_deployment",
            Region = "us-east-1",
            Version = latest.Apply(getStackResult => getStackResult.Version),
            DeploymentTemplateId = "aws-io-optimized-v2",
            TrafficFilters = new[]
            {
                example.Id,
            },
            Elasticsearch = new ElasticCloud.Inputs.DeploymentElasticsearchArgs
            {
                Hot = new ElasticCloud.Inputs.DeploymentElasticsearchHotArgs
                {
                    Autoscaling = null,
                },
            },
            Kibana = null,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ec.EcFunctions;
    import com.pulumi.ec.inputs.GetStackArgs;
    import com.pulumi.ec.DeploymentTrafficFilter;
    import com.pulumi.ec.DeploymentTrafficFilterArgs;
    import com.pulumi.ec.inputs.DeploymentTrafficFilterRuleArgs;
    import com.pulumi.ec.Deployment;
    import com.pulumi.ec.DeploymentArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchHotArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchHotAutoscalingArgs;
    import com.pulumi.ec.inputs.DeploymentKibanaArgs;
    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) {
            final var latest = EcFunctions.getStack(GetStackArgs.builder()
                .versionRegex("latest")
                .region("us-east-1")
                .build());
    
            var example = new DeploymentTrafficFilter("example", DeploymentTrafficFilterArgs.builder()
                .name("my traffic filter name")
                .region("us-east-1")
                .type("ip")
                .rules(DeploymentTrafficFilterRuleArgs.builder()
                    .source("0.0.0.0/0")
                    .build())
                .build());
    
            // Create an Elastic Cloud deployment
            var exampleMinimal = new Deployment("exampleMinimal", DeploymentArgs.builder()
                .name("my_example_deployment")
                .region("us-east-1")
                .version(latest.applyValue(getStackResult -> getStackResult.version()))
                .deploymentTemplateId("aws-io-optimized-v2")
                .trafficFilters(example.id())
                .elasticsearch(DeploymentElasticsearchArgs.builder()
                    .hot(DeploymentElasticsearchHotArgs.builder()
                        .autoscaling()
                        .build())
                    .build())
                .kibana()
                .build());
    
        }
    }
    
    resources:
      # Create an Elastic Cloud deployment
      exampleMinimal:
        type: ec:Deployment
        name: example_minimal
        properties:
          name: my_example_deployment
          region: us-east-1
          version: ${latest.version}
          deploymentTemplateId: aws-io-optimized-v2
          trafficFilters:
            - ${example.id}
          elasticsearch:
            hot:
              autoscaling: {}
          kibana: {}
      example:
        type: ec:DeploymentTrafficFilter
        properties:
          name: my traffic filter name
          region: us-east-1
          type: ip
          rules:
            - source: 0.0.0.0/0
    variables:
      latest:
        fn::invoke:
          Function: ec:getStack
          Arguments:
            versionRegex: latest
            region: us-east-1
    
    import * as pulumi from "@pulumi/pulumi";
    import * as ec from "@pulumi/ec";
    
    const region = azure_australiaeast;
    const latest = ec.getStack({
        versionRegex: "latest",
        region: region,
    });
    const azure = new ec.DeploymentTrafficFilter("azure", {
        name: "my traffic filter name",
        region: region,
        type: "azure_private_endpoint",
        rules: [{
            azureEndpointName: "my-azure-pl",
            azureEndpointGuid: "78c64959-fd88-41cc-81ac-1cfcdb1ac32e",
        }],
    });
    // Create an Elastic Cloud deployment
    const exampleMinimal = new ec.Deployment("example_minimal", {
        name: "my_example_deployment",
        region: region,
        version: latest.then(latest => latest.version),
        deploymentTemplateId: "azure-io-optimized-v3",
        trafficFilters: [azure.id],
        elasticsearch: {
            hot: {
                autoscaling: {},
            },
        },
        kibana: {},
    });
    
    import pulumi
    import pulumi_ec as ec
    
    region = azure_australiaeast
    latest = ec.get_stack(version_regex="latest",
        region=region)
    azure = ec.DeploymentTrafficFilter("azure",
        name="my traffic filter name",
        region=region,
        type="azure_private_endpoint",
        rules=[{
            "azure_endpoint_name": "my-azure-pl",
            "azure_endpoint_guid": "78c64959-fd88-41cc-81ac-1cfcdb1ac32e",
        }])
    # Create an Elastic Cloud deployment
    example_minimal = ec.Deployment("example_minimal",
        name="my_example_deployment",
        region=region,
        version=latest.version,
        deployment_template_id="azure-io-optimized-v3",
        traffic_filters=[azure.id],
        elasticsearch={
            "hot": {
                "autoscaling": {},
            },
        },
        kibana={})
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-ec/sdk/go/ec"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		region := azure_australiaeast
    		latest, err := ec.GetStack(ctx, &ec.GetStackArgs{
    			VersionRegex: "latest",
    			Region:       region,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		azure, err := ec.NewDeploymentTrafficFilter(ctx, "azure", &ec.DeploymentTrafficFilterArgs{
    			Name:   pulumi.String("my traffic filter name"),
    			Region: pulumi.Any(region),
    			Type:   pulumi.String("azure_private_endpoint"),
    			Rules: ec.DeploymentTrafficFilterRuleArray{
    				&ec.DeploymentTrafficFilterRuleArgs{
    					AzureEndpointName: pulumi.String("my-azure-pl"),
    					AzureEndpointGuid: pulumi.String("78c64959-fd88-41cc-81ac-1cfcdb1ac32e"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		// Create an Elastic Cloud deployment
    		_, err = ec.NewDeployment(ctx, "example_minimal", &ec.DeploymentArgs{
    			Name:                 pulumi.String("my_example_deployment"),
    			Region:               pulumi.Any(region),
    			Version:              pulumi.String(latest.Version),
    			DeploymentTemplateId: pulumi.String("azure-io-optimized-v3"),
    			TrafficFilters: pulumi.StringArray{
    				azure.ID(),
    			},
    			Elasticsearch: &ec.DeploymentElasticsearchArgs{
    				Hot: &ec.DeploymentElasticsearchHotArgs{
    					Autoscaling: nil,
    				},
    			},
    			Kibana: nil,
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using ElasticCloud = Pulumi.ElasticCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var region = azure_australiaeast;
    
        var latest = ElasticCloud.GetStack.Invoke(new()
        {
            VersionRegex = "latest",
            Region = region,
        });
    
        var azure = new ElasticCloud.DeploymentTrafficFilter("azure", new()
        {
            Name = "my traffic filter name",
            Region = region,
            Type = "azure_private_endpoint",
            Rules = new[]
            {
                new ElasticCloud.Inputs.DeploymentTrafficFilterRuleArgs
                {
                    AzureEndpointName = "my-azure-pl",
                    AzureEndpointGuid = "78c64959-fd88-41cc-81ac-1cfcdb1ac32e",
                },
            },
        });
    
        // Create an Elastic Cloud deployment
        var exampleMinimal = new ElasticCloud.Deployment("example_minimal", new()
        {
            Name = "my_example_deployment",
            Region = region,
            Version = latest.Apply(getStackResult => getStackResult.Version),
            DeploymentTemplateId = "azure-io-optimized-v3",
            TrafficFilters = new[]
            {
                azure.Id,
            },
            Elasticsearch = new ElasticCloud.Inputs.DeploymentElasticsearchArgs
            {
                Hot = new ElasticCloud.Inputs.DeploymentElasticsearchHotArgs
                {
                    Autoscaling = null,
                },
            },
            Kibana = null,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ec.EcFunctions;
    import com.pulumi.ec.inputs.GetStackArgs;
    import com.pulumi.ec.DeploymentTrafficFilter;
    import com.pulumi.ec.DeploymentTrafficFilterArgs;
    import com.pulumi.ec.inputs.DeploymentTrafficFilterRuleArgs;
    import com.pulumi.ec.Deployment;
    import com.pulumi.ec.DeploymentArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchHotArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchHotAutoscalingArgs;
    import com.pulumi.ec.inputs.DeploymentKibanaArgs;
    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) {
            final var region = azure_australiaeast;
    
            final var latest = EcFunctions.getStack(GetStackArgs.builder()
                .versionRegex("latest")
                .region(region)
                .build());
    
            var azure = new DeploymentTrafficFilter("azure", DeploymentTrafficFilterArgs.builder()
                .name("my traffic filter name")
                .region(region)
                .type("azure_private_endpoint")
                .rules(DeploymentTrafficFilterRuleArgs.builder()
                    .azureEndpointName("my-azure-pl")
                    .azureEndpointGuid("78c64959-fd88-41cc-81ac-1cfcdb1ac32e")
                    .build())
                .build());
    
            // Create an Elastic Cloud deployment
            var exampleMinimal = new Deployment("exampleMinimal", DeploymentArgs.builder()
                .name("my_example_deployment")
                .region(region)
                .version(latest.applyValue(getStackResult -> getStackResult.version()))
                .deploymentTemplateId("azure-io-optimized-v3")
                .trafficFilters(azure.id())
                .elasticsearch(DeploymentElasticsearchArgs.builder()
                    .hot(DeploymentElasticsearchHotArgs.builder()
                        .autoscaling()
                        .build())
                    .build())
                .kibana()
                .build());
    
        }
    }
    
    resources:
      # Create an Elastic Cloud deployment
      exampleMinimal:
        type: ec:Deployment
        name: example_minimal
        properties:
          name: my_example_deployment
          region: ${region}
          version: ${latest.version}
          deploymentTemplateId: azure-io-optimized-v3
          trafficFilters:
            - ${azure.id}
          elasticsearch:
            hot:
              autoscaling: {}
          kibana: {}
      azure:
        type: ec:DeploymentTrafficFilter
        properties:
          name: my traffic filter name
          region: ${region}
          type: azure_private_endpoint
          rules:
            - azureEndpointName: my-azure-pl
              azureEndpointGuid: 78c64959-fd88-41cc-81ac-1cfcdb1ac32e
    variables:
      region: ${["azure-australiaeast"]}
      latest:
        fn::invoke:
          Function: ec:getStack
          Arguments:
            versionRegex: latest
            region: ${region}
    

    ###GCP Private Service Connect traffic filter

    import * as pulumi from "@pulumi/pulumi";
    import * as ec from "@pulumi/ec";
    
    const region = asia_east1;
    const latest = ec.getStack({
        versionRegex: "latest",
        region: region,
    });
    const gcpPsc = new ec.DeploymentTrafficFilter("gcp_psc", {
        name: "my traffic filter name",
        region: region,
        type: "gcp_private_service_connect_endpoint",
        rules: [{
            source: "18446744072646845332",
        }],
    });
    // Create an Elastic Cloud deployment
    const exampleMinimal = new ec.Deployment("example_minimal", {
        name: "my_example_deployment",
        region: region,
        version: latest.then(latest => latest.version),
        deploymentTemplateId: "gcp-storage-optimized",
        trafficFilters: [gcpPsc.id],
        elasticsearch: {
            hot: {
                autoscaling: {},
            },
        },
        kibana: {},
    });
    
    import pulumi
    import pulumi_ec as ec
    
    region = asia_east1
    latest = ec.get_stack(version_regex="latest",
        region=region)
    gcp_psc = ec.DeploymentTrafficFilter("gcp_psc",
        name="my traffic filter name",
        region=region,
        type="gcp_private_service_connect_endpoint",
        rules=[{
            "source": "18446744072646845332",
        }])
    # Create an Elastic Cloud deployment
    example_minimal = ec.Deployment("example_minimal",
        name="my_example_deployment",
        region=region,
        version=latest.version,
        deployment_template_id="gcp-storage-optimized",
        traffic_filters=[gcp_psc.id],
        elasticsearch={
            "hot": {
                "autoscaling": {},
            },
        },
        kibana={})
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-ec/sdk/go/ec"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		region := asia_east1
    		latest, err := ec.GetStack(ctx, &ec.GetStackArgs{
    			VersionRegex: "latest",
    			Region:       region,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		gcpPsc, err := ec.NewDeploymentTrafficFilter(ctx, "gcp_psc", &ec.DeploymentTrafficFilterArgs{
    			Name:   pulumi.String("my traffic filter name"),
    			Region: pulumi.Any(region),
    			Type:   pulumi.String("gcp_private_service_connect_endpoint"),
    			Rules: ec.DeploymentTrafficFilterRuleArray{
    				&ec.DeploymentTrafficFilterRuleArgs{
    					Source: pulumi.String("18446744072646845332"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		// Create an Elastic Cloud deployment
    		_, err = ec.NewDeployment(ctx, "example_minimal", &ec.DeploymentArgs{
    			Name:                 pulumi.String("my_example_deployment"),
    			Region:               pulumi.Any(region),
    			Version:              pulumi.String(latest.Version),
    			DeploymentTemplateId: pulumi.String("gcp-storage-optimized"),
    			TrafficFilters: pulumi.StringArray{
    				gcpPsc.ID(),
    			},
    			Elasticsearch: &ec.DeploymentElasticsearchArgs{
    				Hot: &ec.DeploymentElasticsearchHotArgs{
    					Autoscaling: nil,
    				},
    			},
    			Kibana: nil,
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using ElasticCloud = Pulumi.ElasticCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var region = asia_east1;
    
        var latest = ElasticCloud.GetStack.Invoke(new()
        {
            VersionRegex = "latest",
            Region = region,
        });
    
        var gcpPsc = new ElasticCloud.DeploymentTrafficFilter("gcp_psc", new()
        {
            Name = "my traffic filter name",
            Region = region,
            Type = "gcp_private_service_connect_endpoint",
            Rules = new[]
            {
                new ElasticCloud.Inputs.DeploymentTrafficFilterRuleArgs
                {
                    Source = "18446744072646845332",
                },
            },
        });
    
        // Create an Elastic Cloud deployment
        var exampleMinimal = new ElasticCloud.Deployment("example_minimal", new()
        {
            Name = "my_example_deployment",
            Region = region,
            Version = latest.Apply(getStackResult => getStackResult.Version),
            DeploymentTemplateId = "gcp-storage-optimized",
            TrafficFilters = new[]
            {
                gcpPsc.Id,
            },
            Elasticsearch = new ElasticCloud.Inputs.DeploymentElasticsearchArgs
            {
                Hot = new ElasticCloud.Inputs.DeploymentElasticsearchHotArgs
                {
                    Autoscaling = null,
                },
            },
            Kibana = null,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ec.EcFunctions;
    import com.pulumi.ec.inputs.GetStackArgs;
    import com.pulumi.ec.DeploymentTrafficFilter;
    import com.pulumi.ec.DeploymentTrafficFilterArgs;
    import com.pulumi.ec.inputs.DeploymentTrafficFilterRuleArgs;
    import com.pulumi.ec.Deployment;
    import com.pulumi.ec.DeploymentArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchHotArgs;
    import com.pulumi.ec.inputs.DeploymentElasticsearchHotAutoscalingArgs;
    import com.pulumi.ec.inputs.DeploymentKibanaArgs;
    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) {
            final var region = asia_east1;
    
            final var latest = EcFunctions.getStack(GetStackArgs.builder()
                .versionRegex("latest")
                .region(region)
                .build());
    
            var gcpPsc = new DeploymentTrafficFilter("gcpPsc", DeploymentTrafficFilterArgs.builder()
                .name("my traffic filter name")
                .region(region)
                .type("gcp_private_service_connect_endpoint")
                .rules(DeploymentTrafficFilterRuleArgs.builder()
                    .source("18446744072646845332")
                    .build())
                .build());
    
            // Create an Elastic Cloud deployment
            var exampleMinimal = new Deployment("exampleMinimal", DeploymentArgs.builder()
                .name("my_example_deployment")
                .region(region)
                .version(latest.applyValue(getStackResult -> getStackResult.version()))
                .deploymentTemplateId("gcp-storage-optimized")
                .trafficFilters(gcpPsc.id())
                .elasticsearch(DeploymentElasticsearchArgs.builder()
                    .hot(DeploymentElasticsearchHotArgs.builder()
                        .autoscaling()
                        .build())
                    .build())
                .kibana()
                .build());
    
        }
    }
    
    resources:
      # Create an Elastic Cloud deployment
      exampleMinimal:
        type: ec:Deployment
        name: example_minimal
        properties:
          name: my_example_deployment
          region: ${region}
          version: ${latest.version}
          deploymentTemplateId: gcp-storage-optimized
          trafficFilters:
            - ${gcpPsc.id}
          elasticsearch:
            hot:
              autoscaling: {}
          kibana: {}
      gcpPsc:
        type: ec:DeploymentTrafficFilter
        name: gcp_psc
        properties:
          name: my traffic filter name
          region: ${region}
          type: gcp_private_service_connect_endpoint
          rules:
            - source: '18446744072646845332'
    variables:
      region: ${["asia-east1"]}
      latest:
        fn::invoke:
          Function: ec:getStack
          Arguments:
            versionRegex: latest
            region: ${region}
    

    Create DeploymentTrafficFilter Resource

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

    Constructor syntax

    new DeploymentTrafficFilter(name: string, args: DeploymentTrafficFilterArgs, opts?: CustomResourceOptions);
    @overload
    def DeploymentTrafficFilter(resource_name: str,
                                args: DeploymentTrafficFilterArgs,
                                opts: Optional[ResourceOptions] = None)
    
    @overload
    def DeploymentTrafficFilter(resource_name: str,
                                opts: Optional[ResourceOptions] = None,
                                region: Optional[str] = None,
                                type: Optional[str] = None,
                                description: Optional[str] = None,
                                include_by_default: Optional[bool] = None,
                                name: Optional[str] = None,
                                rules: Optional[Sequence[DeploymentTrafficFilterRuleArgs]] = None)
    func NewDeploymentTrafficFilter(ctx *Context, name string, args DeploymentTrafficFilterArgs, opts ...ResourceOption) (*DeploymentTrafficFilter, error)
    public DeploymentTrafficFilter(string name, DeploymentTrafficFilterArgs args, CustomResourceOptions? opts = null)
    public DeploymentTrafficFilter(String name, DeploymentTrafficFilterArgs args)
    public DeploymentTrafficFilter(String name, DeploymentTrafficFilterArgs args, CustomResourceOptions options)
    
    type: ec:DeploymentTrafficFilter
    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 DeploymentTrafficFilterArgs
    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 DeploymentTrafficFilterArgs
    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 DeploymentTrafficFilterArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DeploymentTrafficFilterArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DeploymentTrafficFilterArgs
    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 deploymentTrafficFilterResource = new ElasticCloud.DeploymentTrafficFilter("deploymentTrafficFilterResource", new()
    {
        Region = "string",
        Type = "string",
        Description = "string",
        IncludeByDefault = false,
        Name = "string",
        Rules = new[]
        {
            new ElasticCloud.Inputs.DeploymentTrafficFilterRuleArgs
            {
                AzureEndpointGuid = "string",
                AzureEndpointName = "string",
                Description = "string",
                Id = "string",
                Source = "string",
            },
        },
    });
    
    example, err := ec.NewDeploymentTrafficFilter(ctx, "deploymentTrafficFilterResource", &ec.DeploymentTrafficFilterArgs{
    	Region:           pulumi.String("string"),
    	Type:             pulumi.String("string"),
    	Description:      pulumi.String("string"),
    	IncludeByDefault: pulumi.Bool(false),
    	Name:             pulumi.String("string"),
    	Rules: ec.DeploymentTrafficFilterRuleArray{
    		&ec.DeploymentTrafficFilterRuleArgs{
    			AzureEndpointGuid: pulumi.String("string"),
    			AzureEndpointName: pulumi.String("string"),
    			Description:       pulumi.String("string"),
    			Id:                pulumi.String("string"),
    			Source:            pulumi.String("string"),
    		},
    	},
    })
    
    var deploymentTrafficFilterResource = new DeploymentTrafficFilter("deploymentTrafficFilterResource", DeploymentTrafficFilterArgs.builder()
        .region("string")
        .type("string")
        .description("string")
        .includeByDefault(false)
        .name("string")
        .rules(DeploymentTrafficFilterRuleArgs.builder()
            .azureEndpointGuid("string")
            .azureEndpointName("string")
            .description("string")
            .id("string")
            .source("string")
            .build())
        .build());
    
    deployment_traffic_filter_resource = ec.DeploymentTrafficFilter("deploymentTrafficFilterResource",
        region="string",
        type="string",
        description="string",
        include_by_default=False,
        name="string",
        rules=[{
            "azure_endpoint_guid": "string",
            "azure_endpoint_name": "string",
            "description": "string",
            "id": "string",
            "source": "string",
        }])
    
    const deploymentTrafficFilterResource = new ec.DeploymentTrafficFilter("deploymentTrafficFilterResource", {
        region: "string",
        type: "string",
        description: "string",
        includeByDefault: false,
        name: "string",
        rules: [{
            azureEndpointGuid: "string",
            azureEndpointName: "string",
            description: "string",
            id: "string",
            source: "string",
        }],
    });
    
    type: ec:DeploymentTrafficFilter
    properties:
        description: string
        includeByDefault: false
        name: string
        region: string
        rules:
            - azureEndpointGuid: string
              azureEndpointName: string
              description: string
              id: string
              source: string
        type: string
    

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

    Region string
    Filter region, the ruleset can only be attached to deployments in the specific region
    Type string
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    Description string
    Ruleset description
    IncludeByDefault bool
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    Name string
    Name of the ruleset
    Rules List<Pulumi.ElasticCloud.Inputs.DeploymentTrafficFilterRule>
    Set of rules, which the ruleset is made of.
    Region string
    Filter region, the ruleset can only be attached to deployments in the specific region
    Type string
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    Description string
    Ruleset description
    IncludeByDefault bool
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    Name string
    Name of the ruleset
    Rules []DeploymentTrafficFilterRuleArgs
    Set of rules, which the ruleset is made of.
    region String
    Filter region, the ruleset can only be attached to deployments in the specific region
    type String
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description String
    Ruleset description
    includeByDefault Boolean
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name String
    Name of the ruleset
    rules List<DeploymentTrafficFilterRule>
    Set of rules, which the ruleset is made of.
    region string
    Filter region, the ruleset can only be attached to deployments in the specific region
    type string
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description string
    Ruleset description
    includeByDefault boolean
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name string
    Name of the ruleset
    rules DeploymentTrafficFilterRule[]
    Set of rules, which the ruleset is made of.
    region str
    Filter region, the ruleset can only be attached to deployments in the specific region
    type str
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description str
    Ruleset description
    include_by_default bool
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name str
    Name of the ruleset
    rules Sequence[DeploymentTrafficFilterRuleArgs]
    Set of rules, which the ruleset is made of.
    region String
    Filter region, the ruleset can only be attached to deployments in the specific region
    type String
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description String
    Ruleset description
    includeByDefault Boolean
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name String
    Name of the ruleset
    rules List<Property Map>
    Set of rules, which the ruleset is made of.

    Outputs

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

    Get an existing DeploymentTrafficFilter 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?: DeploymentTrafficFilterState, opts?: CustomResourceOptions): DeploymentTrafficFilter
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            description: Optional[str] = None,
            include_by_default: Optional[bool] = None,
            name: Optional[str] = None,
            region: Optional[str] = None,
            rules: Optional[Sequence[DeploymentTrafficFilterRuleArgs]] = None,
            type: Optional[str] = None) -> DeploymentTrafficFilter
    func GetDeploymentTrafficFilter(ctx *Context, name string, id IDInput, state *DeploymentTrafficFilterState, opts ...ResourceOption) (*DeploymentTrafficFilter, error)
    public static DeploymentTrafficFilter Get(string name, Input<string> id, DeploymentTrafficFilterState? state, CustomResourceOptions? opts = null)
    public static DeploymentTrafficFilter get(String name, Output<String> id, DeploymentTrafficFilterState 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:
    Description string
    Ruleset description
    IncludeByDefault bool
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    Name string
    Name of the ruleset
    Region string
    Filter region, the ruleset can only be attached to deployments in the specific region
    Rules List<Pulumi.ElasticCloud.Inputs.DeploymentTrafficFilterRule>
    Set of rules, which the ruleset is made of.
    Type string
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    Description string
    Ruleset description
    IncludeByDefault bool
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    Name string
    Name of the ruleset
    Region string
    Filter region, the ruleset can only be attached to deployments in the specific region
    Rules []DeploymentTrafficFilterRuleArgs
    Set of rules, which the ruleset is made of.
    Type string
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description String
    Ruleset description
    includeByDefault Boolean
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name String
    Name of the ruleset
    region String
    Filter region, the ruleset can only be attached to deployments in the specific region
    rules List<DeploymentTrafficFilterRule>
    Set of rules, which the ruleset is made of.
    type String
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description string
    Ruleset description
    includeByDefault boolean
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name string
    Name of the ruleset
    region string
    Filter region, the ruleset can only be attached to deployments in the specific region
    rules DeploymentTrafficFilterRule[]
    Set of rules, which the ruleset is made of.
    type string
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description str
    Ruleset description
    include_by_default bool
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name str
    Name of the ruleset
    region str
    Filter region, the ruleset can only be attached to deployments in the specific region
    rules Sequence[DeploymentTrafficFilterRuleArgs]
    Set of rules, which the ruleset is made of.
    type str
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint
    description String
    Ruleset description
    includeByDefault Boolean
    Indicates that the ruleset should be automatically included in new deployments (Defaults to false)
    name String
    Name of the ruleset
    region String
    Filter region, the ruleset can only be attached to deployments in the specific region
    rules List<Property Map>
    Set of rules, which the ruleset is made of.
    type String
    Type of the ruleset. It can be ip, vpce, azure_private_endpoint, or gcp_private_service_connect_endpoint

    Supporting Types

    DeploymentTrafficFilterRule, DeploymentTrafficFilterRuleArgs

    AzureEndpointGuid string
    Azure endpoint GUID. Only applicable when the ruleset type is set to azure_private_endpoint
    AzureEndpointName string
    Azure endpoint name. Only applicable when the ruleset type is set to azure_private_endpoint
    Description string
    Description of this individual rule
    Id string
    Computed rule ID
    Source string
    Traffic filter source: IP address, CIDR mask, or VPC endpoint ID, only required when the type is not azure_private_endpoint
    AzureEndpointGuid string
    Azure endpoint GUID. Only applicable when the ruleset type is set to azure_private_endpoint
    AzureEndpointName string
    Azure endpoint name. Only applicable when the ruleset type is set to azure_private_endpoint
    Description string
    Description of this individual rule
    Id string
    Computed rule ID
    Source string
    Traffic filter source: IP address, CIDR mask, or VPC endpoint ID, only required when the type is not azure_private_endpoint
    azureEndpointGuid String
    Azure endpoint GUID. Only applicable when the ruleset type is set to azure_private_endpoint
    azureEndpointName String
    Azure endpoint name. Only applicable when the ruleset type is set to azure_private_endpoint
    description String
    Description of this individual rule
    id String
    Computed rule ID
    source String
    Traffic filter source: IP address, CIDR mask, or VPC endpoint ID, only required when the type is not azure_private_endpoint
    azureEndpointGuid string
    Azure endpoint GUID. Only applicable when the ruleset type is set to azure_private_endpoint
    azureEndpointName string
    Azure endpoint name. Only applicable when the ruleset type is set to azure_private_endpoint
    description string
    Description of this individual rule
    id string
    Computed rule ID
    source string
    Traffic filter source: IP address, CIDR mask, or VPC endpoint ID, only required when the type is not azure_private_endpoint
    azure_endpoint_guid str
    Azure endpoint GUID. Only applicable when the ruleset type is set to azure_private_endpoint
    azure_endpoint_name str
    Azure endpoint name. Only applicable when the ruleset type is set to azure_private_endpoint
    description str
    Description of this individual rule
    id str
    Computed rule ID
    source str
    Traffic filter source: IP address, CIDR mask, or VPC endpoint ID, only required when the type is not azure_private_endpoint
    azureEndpointGuid String
    Azure endpoint GUID. Only applicable when the ruleset type is set to azure_private_endpoint
    azureEndpointName String
    Azure endpoint name. Only applicable when the ruleset type is set to azure_private_endpoint
    description String
    Description of this individual rule
    id String
    Computed rule ID
    source String
    Traffic filter source: IP address, CIDR mask, or VPC endpoint ID, only required when the type is not azure_private_endpoint

    Import

    Traffic filters can be imported using the id, for example:

    $ pulumi import ec:index/deploymentTrafficFilter:DeploymentTrafficFilter name 320b7b540dfc967a7a649c18e2fce4ed
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    ec pulumi/pulumi-ec
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ec Terraform Provider.
    ec logo
    ElasticCloud (EC) v0.10.2 published on Wednesday, Oct 2, 2024 by Pulumi