1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. AntiddosDdosSpeedLimitConfig
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.AntiddosDdosSpeedLimitConfig

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Provides a resource to create a antiddos ddos speed limit config

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const ddosSpeedLimitConfig = new tencentcloud.AntiddosDdosSpeedLimitConfig("ddosSpeedLimitConfig", {
        ddosSpeedLimitConfig: {
            dstPortList: "8000",
            mode: 1,
            protocolList: "ALL",
            speedValues: [
                {
                    type: 1,
                    value: 1,
                },
                {
                    type: 2,
                    value: 2,
                },
            ],
        },
        instanceId: "bgp-xxxxxx",
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    ddos_speed_limit_config = tencentcloud.AntiddosDdosSpeedLimitConfig("ddosSpeedLimitConfig",
        ddos_speed_limit_config={
            "dst_port_list": "8000",
            "mode": 1,
            "protocol_list": "ALL",
            "speed_values": [
                {
                    "type": 1,
                    "value": 1,
                },
                {
                    "type": 2,
                    "value": 2,
                },
            ],
        },
        instance_id="bgp-xxxxxx")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.NewAntiddosDdosSpeedLimitConfig(ctx, "ddosSpeedLimitConfig", &tencentcloud.AntiddosDdosSpeedLimitConfigArgs{
    			DdosSpeedLimitConfig: &tencentcloud.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs{
    				DstPortList:  pulumi.String("8000"),
    				Mode:         pulumi.Float64(1),
    				ProtocolList: pulumi.String("ALL"),
    				SpeedValues: tencentcloud.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArray{
    					&tencentcloud.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArgs{
    						Type:  pulumi.Float64(1),
    						Value: pulumi.Float64(1),
    					},
    					&tencentcloud.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArgs{
    						Type:  pulumi.Float64(2),
    						Value: pulumi.Float64(2),
    					},
    				},
    			},
    			InstanceId: pulumi.String("bgp-xxxxxx"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var ddosSpeedLimitConfig = new Tencentcloud.AntiddosDdosSpeedLimitConfig("ddosSpeedLimitConfig", new()
        {
            DdosSpeedLimitConfig = new Tencentcloud.Inputs.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs
            {
                DstPortList = "8000",
                Mode = 1,
                ProtocolList = "ALL",
                SpeedValues = new[]
                {
                    new Tencentcloud.Inputs.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArgs
                    {
                        Type = 1,
                        Value = 1,
                    },
                    new Tencentcloud.Inputs.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArgs
                    {
                        Type = 2,
                        Value = 2,
                    },
                },
            },
            InstanceId = "bgp-xxxxxx",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.AntiddosDdosSpeedLimitConfig;
    import com.pulumi.tencentcloud.AntiddosDdosSpeedLimitConfigArgs;
    import com.pulumi.tencentcloud.inputs.AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs;
    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 ddosSpeedLimitConfig = new AntiddosDdosSpeedLimitConfig("ddosSpeedLimitConfig", AntiddosDdosSpeedLimitConfigArgs.builder()
                .ddosSpeedLimitConfig(AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs.builder()
                    .dstPortList("8000")
                    .mode(1)
                    .protocolList("ALL")
                    .speedValues(                
                        AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArgs.builder()
                            .type(1)
                            .value(1)
                            .build(),
                        AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArgs.builder()
                            .type(2)
                            .value(2)
                            .build())
                    .build())
                .instanceId("bgp-xxxxxx")
                .build());
    
        }
    }
    
    resources:
      ddosSpeedLimitConfig:
        type: tencentcloud:AntiddosDdosSpeedLimitConfig
        properties:
          ddosSpeedLimitConfig:
            dstPortList: '8000'
            mode: 1
            protocolList: ALL
            speedValues:
              - type: 1
                value: 1
              - type: 2
                value: 2
          instanceId: bgp-xxxxxx
    

    Create AntiddosDdosSpeedLimitConfig Resource

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

    Constructor syntax

    new AntiddosDdosSpeedLimitConfig(name: string, args: AntiddosDdosSpeedLimitConfigArgs, opts?: CustomResourceOptions);
    @overload
    def AntiddosDdosSpeedLimitConfig(resource_name: str,
                                     args: AntiddosDdosSpeedLimitConfigArgs,
                                     opts: Optional[ResourceOptions] = None)
    
    @overload
    def AntiddosDdosSpeedLimitConfig(resource_name: str,
                                     opts: Optional[ResourceOptions] = None,
                                     ddos_speed_limit_config: Optional[AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs] = None,
                                     instance_id: Optional[str] = None,
                                     antiddos_ddos_speed_limit_config_id: Optional[str] = None)
    func NewAntiddosDdosSpeedLimitConfig(ctx *Context, name string, args AntiddosDdosSpeedLimitConfigArgs, opts ...ResourceOption) (*AntiddosDdosSpeedLimitConfig, error)
    public AntiddosDdosSpeedLimitConfig(string name, AntiddosDdosSpeedLimitConfigArgs args, CustomResourceOptions? opts = null)
    public AntiddosDdosSpeedLimitConfig(String name, AntiddosDdosSpeedLimitConfigArgs args)
    public AntiddosDdosSpeedLimitConfig(String name, AntiddosDdosSpeedLimitConfigArgs args, CustomResourceOptions options)
    
    type: tencentcloud:AntiddosDdosSpeedLimitConfig
    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 AntiddosDdosSpeedLimitConfigArgs
    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 AntiddosDdosSpeedLimitConfigArgs
    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 AntiddosDdosSpeedLimitConfigArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args AntiddosDdosSpeedLimitConfigArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args AntiddosDdosSpeedLimitConfigArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

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

    DdosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfig
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    InstanceId string
    InstanceId.
    AntiddosDdosSpeedLimitConfigId string
    ID of the resource.
    DdosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    InstanceId string
    InstanceId.
    AntiddosDdosSpeedLimitConfigId string
    ID of the resource.
    ddosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfig
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instanceId String
    InstanceId.
    antiddosDdosSpeedLimitConfigId String
    ID of the resource.
    ddosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfig
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instanceId string
    InstanceId.
    antiddosDdosSpeedLimitConfigId string
    ID of the resource.
    ddos_speed_limit_config AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instance_id str
    InstanceId.
    antiddos_ddos_speed_limit_config_id str
    ID of the resource.
    ddosSpeedLimitConfig Property Map
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instanceId String
    InstanceId.
    antiddosDdosSpeedLimitConfigId String
    ID of the resource.

    Outputs

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

    Get an existing AntiddosDdosSpeedLimitConfig 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?: AntiddosDdosSpeedLimitConfigState, opts?: CustomResourceOptions): AntiddosDdosSpeedLimitConfig
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            antiddos_ddos_speed_limit_config_id: Optional[str] = None,
            ddos_speed_limit_config: Optional[AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs] = None,
            instance_id: Optional[str] = None) -> AntiddosDdosSpeedLimitConfig
    func GetAntiddosDdosSpeedLimitConfig(ctx *Context, name string, id IDInput, state *AntiddosDdosSpeedLimitConfigState, opts ...ResourceOption) (*AntiddosDdosSpeedLimitConfig, error)
    public static AntiddosDdosSpeedLimitConfig Get(string name, Input<string> id, AntiddosDdosSpeedLimitConfigState? state, CustomResourceOptions? opts = null)
    public static AntiddosDdosSpeedLimitConfig get(String name, Output<String> id, AntiddosDdosSpeedLimitConfigState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:AntiddosDdosSpeedLimitConfig    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AntiddosDdosSpeedLimitConfigId string
    ID of the resource.
    DdosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfig
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    InstanceId string
    InstanceId.
    AntiddosDdosSpeedLimitConfigId string
    ID of the resource.
    DdosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    InstanceId string
    InstanceId.
    antiddosDdosSpeedLimitConfigId String
    ID of the resource.
    ddosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfig
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instanceId String
    InstanceId.
    antiddosDdosSpeedLimitConfigId string
    ID of the resource.
    ddosSpeedLimitConfig AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfig
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instanceId string
    InstanceId.
    antiddos_ddos_speed_limit_config_id str
    ID of the resource.
    ddos_speed_limit_config AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instance_id str
    InstanceId.
    antiddosDdosSpeedLimitConfigId String
    ID of the resource.
    ddosSpeedLimitConfig Property Map
    Accessing speed limit configuration, the configuration ID cannot be empty when filling in parameters.
    instanceId String
    InstanceId.

    Supporting Types

    AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfig, AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigArgs

    Mode double
    Speed limit mode, value [1 (based on source IP speed limit) 2 (based on destination port speed limit)].
    SpeedValues List<AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValue>
    Speed limit values, each type of speed limit value can support up to 1; This field array has at least one speed limit value.
    DstPortList string
    List of port ranges, up to 8, multiple; Separate and indicate the range with -; This port range must be filled in; Fill in style 1:0-65535, style 2: 80; 443; 1000-2000.
    DstPortScopes List<AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigDstPortScope>
    This field has been deprecated. Please fill in the new field DstPortList.
    ProtocolList string
    IP protocol numbers, values [ALL (all protocols) TCP (tcp protocol) UDP (udp protocol) SMP (smp protocol) 1; 2-100 (custom protocol number range, up to 8)] Note: When customizing the protocol number range, only the protocol number can be filled in, multiple ranges; Separation; When filling in ALL, no other agreements or agreements can be filled inNumber.
    Mode float64
    Speed limit mode, value [1 (based on source IP speed limit) 2 (based on destination port speed limit)].
    SpeedValues []AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValue
    Speed limit values, each type of speed limit value can support up to 1; This field array has at least one speed limit value.
    DstPortList string
    List of port ranges, up to 8, multiple; Separate and indicate the range with -; This port range must be filled in; Fill in style 1:0-65535, style 2: 80; 443; 1000-2000.
    DstPortScopes []AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigDstPortScope
    This field has been deprecated. Please fill in the new field DstPortList.
    ProtocolList string
    IP protocol numbers, values [ALL (all protocols) TCP (tcp protocol) UDP (udp protocol) SMP (smp protocol) 1; 2-100 (custom protocol number range, up to 8)] Note: When customizing the protocol number range, only the protocol number can be filled in, multiple ranges; Separation; When filling in ALL, no other agreements or agreements can be filled inNumber.
    mode Double
    Speed limit mode, value [1 (based on source IP speed limit) 2 (based on destination port speed limit)].
    speedValues List<AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValue>
    Speed limit values, each type of speed limit value can support up to 1; This field array has at least one speed limit value.
    dstPortList String
    List of port ranges, up to 8, multiple; Separate and indicate the range with -; This port range must be filled in; Fill in style 1:0-65535, style 2: 80; 443; 1000-2000.
    dstPortScopes List<AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigDstPortScope>
    This field has been deprecated. Please fill in the new field DstPortList.
    protocolList String
    IP protocol numbers, values [ALL (all protocols) TCP (tcp protocol) UDP (udp protocol) SMP (smp protocol) 1; 2-100 (custom protocol number range, up to 8)] Note: When customizing the protocol number range, only the protocol number can be filled in, multiple ranges; Separation; When filling in ALL, no other agreements or agreements can be filled inNumber.
    mode number
    Speed limit mode, value [1 (based on source IP speed limit) 2 (based on destination port speed limit)].
    speedValues AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValue[]
    Speed limit values, each type of speed limit value can support up to 1; This field array has at least one speed limit value.
    dstPortList string
    List of port ranges, up to 8, multiple; Separate and indicate the range with -; This port range must be filled in; Fill in style 1:0-65535, style 2: 80; 443; 1000-2000.
    dstPortScopes AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigDstPortScope[]
    This field has been deprecated. Please fill in the new field DstPortList.
    protocolList string
    IP protocol numbers, values [ALL (all protocols) TCP (tcp protocol) UDP (udp protocol) SMP (smp protocol) 1; 2-100 (custom protocol number range, up to 8)] Note: When customizing the protocol number range, only the protocol number can be filled in, multiple ranges; Separation; When filling in ALL, no other agreements or agreements can be filled inNumber.
    mode float
    Speed limit mode, value [1 (based on source IP speed limit) 2 (based on destination port speed limit)].
    speed_values Sequence[AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValue]
    Speed limit values, each type of speed limit value can support up to 1; This field array has at least one speed limit value.
    dst_port_list str
    List of port ranges, up to 8, multiple; Separate and indicate the range with -; This port range must be filled in; Fill in style 1:0-65535, style 2: 80; 443; 1000-2000.
    dst_port_scopes Sequence[AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigDstPortScope]
    This field has been deprecated. Please fill in the new field DstPortList.
    protocol_list str
    IP protocol numbers, values [ALL (all protocols) TCP (tcp protocol) UDP (udp protocol) SMP (smp protocol) 1; 2-100 (custom protocol number range, up to 8)] Note: When customizing the protocol number range, only the protocol number can be filled in, multiple ranges; Separation; When filling in ALL, no other agreements or agreements can be filled inNumber.
    mode Number
    Speed limit mode, value [1 (based on source IP speed limit) 2 (based on destination port speed limit)].
    speedValues List<Property Map>
    Speed limit values, each type of speed limit value can support up to 1; This field array has at least one speed limit value.
    dstPortList String
    List of port ranges, up to 8, multiple; Separate and indicate the range with -; This port range must be filled in; Fill in style 1:0-65535, style 2: 80; 443; 1000-2000.
    dstPortScopes List<Property Map>
    This field has been deprecated. Please fill in the new field DstPortList.
    protocolList String
    IP protocol numbers, values [ALL (all protocols) TCP (tcp protocol) UDP (udp protocol) SMP (smp protocol) 1; 2-100 (custom protocol number range, up to 8)] Note: When customizing the protocol number range, only the protocol number can be filled in, multiple ranges; Separation; When filling in ALL, no other agreements or agreements can be filled inNumber.

    AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigDstPortScope, AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigDstPortScopeArgs

    BeginPort double
    Starting port, ranging from 1 to 65535.
    EndPort double
    end port, ranging from 1 to 65535.
    BeginPort float64
    Starting port, ranging from 1 to 65535.
    EndPort float64
    end port, ranging from 1 to 65535.
    beginPort Double
    Starting port, ranging from 1 to 65535.
    endPort Double
    end port, ranging from 1 to 65535.
    beginPort number
    Starting port, ranging from 1 to 65535.
    endPort number
    end port, ranging from 1 to 65535.
    begin_port float
    Starting port, ranging from 1 to 65535.
    end_port float
    end port, ranging from 1 to 65535.
    beginPort Number
    Starting port, ranging from 1 to 65535.
    endPort Number
    end port, ranging from 1 to 65535.

    AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValue, AntiddosDdosSpeedLimitConfigDdosSpeedLimitConfigSpeedValueArgs

    Type double
    Speed limit value type, value [1 (packet rate pps) 2 (bandwidth bps)].
    Value double
    value.
    Type float64
    Speed limit value type, value [1 (packet rate pps) 2 (bandwidth bps)].
    Value float64
    value.
    type Double
    Speed limit value type, value [1 (packet rate pps) 2 (bandwidth bps)].
    value Double
    value.
    type number
    Speed limit value type, value [1 (packet rate pps) 2 (bandwidth bps)].
    value number
    value.
    type float
    Speed limit value type, value [1 (packet rate pps) 2 (bandwidth bps)].
    value float
    value.
    type Number
    Speed limit value type, value [1 (packet rate pps) 2 (bandwidth bps)].
    value Number
    value.

    Import

    antiddos ddos_speed_limit_config can be imported using the id, e.g.

    $ pulumi import tencentcloud:index/antiddosDdosSpeedLimitConfig:AntiddosDdosSpeedLimitConfig ddos_speed_limit_config ${instanceId}#${configId}s
    

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

    Package Details

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