alicloud_ddoscoo_instance
Provides a BGP-line Anti-DDoS Pro(DdosCoo) Instance resource.
For information about BGP-line Anti-DDoS Pro(DdosCoo) Instance and how to use it, see What is Anti-DDoS Pro Instance.
-> NOTE: Available since v1.37.0.
-> NOTE: The endpoint of bssopenapi used only support "business.aliyuncs.com" at present.
-> NOTE: From version 1.214.0, if product_type is set to ddoscoo or ddoscoo_intl, the provider region should be set to cn-hangzhou, and if product_type is set to ddosDip, the provider region should be set to ap-southeast-1.
Example Usage
Basic Usage
provider "alicloud" {
region = "cn-hangzhou"
}
variable "name" {
default = "tf-example"
}
resource "alicloud_ddoscoo_instance" "default" {
name = var.name
base_bandwidth = "30"
bandwidth = "30"
service_bandwidth = "100"
port_count = "50"
domain_count = "50"
product_type = "ddoscoo"
period = "1"
}
Argument Reference
The following arguments are supported:
name- (Required) Name of the instance. This name can have a string of1to64characters.port_count- (Required) Port retransmission rule count of the instance. At least 50. Increase 5 per step, such as 55, 60, 65. Only support upgrade.domain_count- (Required) Domain retransmission rule count of the instance. At least 50. Increase 5 per step, such as 55, 60, 65. Only support upgrade.base_bandwidth- (Optional) Base defend bandwidth of the instance. Valid values:30,60,100,300,400,500,600. The unit is Gbps. Only support upgrade. NOTE:base_bandwidthis valid only whenproduct_typeis set toddoscooorddoscoo_intl.bandwidth- (Optional) Elastic defend bandwidth of the instance. This value must be larger than the base defend bandwidth. Valid values:30,60,100,300,400,500,600. The unit is Gbps. Only support upgrade. NOTE:bandwidthis valid only whenproduct_typeis set toddoscooorddoscoo_intl.service_bandwidth- (Optional) Business bandwidth of the instance. At leaset 100. Increased 100 per step, such as 100, 200, 300. The unit is Mbps. Only support upgrade. NOTE:service_bandwidthis valid only whenproduct_typeis set toddoscooorddoscoo_intl.normal_bandwidth- (Optional, Available since v1.214.0) The clean bandwidth provided by the instance. NOTE:normal_bandwidthis valid only whenproduct_typeis set toddosDip. From version 1.248.0,normal_bandwidthcan be modified.normal_qps- (Optional, Available since v1.214.0) The clean QPS provided by the instance. NOTE:normal_qpsis valid only whenproduct_typeis set toddosDip. From version 1.248.0,normal_qpscan be modified.edition_sale- (Optional, ForceNew, Available since v1.212.0) The mitigation plan of the instance. Default value:coop. Valid values:coop: Anti-DDoS Pro instance of the Profession mitigation plan.
product_plan- (Optional, Available since v1.214.0) The mitigation plan of the instance. Valid values:0: The Insurance mitigation plan.1: The Unlimited mitigation plan.2: The Chinese Mainland Acceleration (CMA) mitigation plan.3: The Secure Chinese Mainland Acceleration (Sec-CMA) mitigation plan. NOTE:product_planis valid only whenproduct_typeis set toddosDip. From version 1.248.0,product_plancan be modified.
address_type- (Optional, ForceNew, Available since v1.212.0) The IP version of the IP address. Default value:Ipv4. Valid values:Ipv4,Ipv6. NOTE:address_typeis valid only whenproduct_typeis set toddoscooorddoscoo_intl.bandwidth_mode- (Optional, Available since v1.212.0) The mitigation plan of the instance. Valid values:0: Disables the burstable clean bandwidth feature.1: Enables the burstable clean bandwidth feature and uses the daily 95th percentile metering method.2: Enables the burstable clean bandwidth feature and uses the monthly 95th percentile metering method. NOTE:bandwidth_modeis valid only whenproduct_typeis set toddoscooorddoscoo_intl.
function_version- (Optional, Available since v1.214.0) The function plan of the instance. Valid values:0: The Standard function plan.1: The Enhanced function plan. NOTE: From version 1.248.0,function_versioncan be modified.
product_type- (Optional, Available since v1.125.0) The product type for purchasing DDOSCOO instances used to differ different account type. Default value:ddoscoo. Valid values:ddoscoo: Anti-DDoS Pro. Only supports domestic account.ddoscoo_intl: Anti-DDoS Pro. Only supports to international account.ddosDip: Anti-DDoS Premium. NOTE: From version 1.214.0,product_typecan be set toddosDip.
period- (Optional, Int) The duration that you will buy DdosCoo instance (in month). Valid values: [1~9],12,24,36. Default value:1. At present, the provider does not support modifyperiod.tags- (Optional, Map, Available since v1.248.0) A mapping of tags to assign to the resource.modify_type- (Optional, Available since v1.248.0) The type of modification. Valid values:UPGRADE,DOWNGRADE.
Attributes Reference
The following attributes are exported:
id- The resource ID in terraform of DdosCoo.ip- (Available since v1.212.0) The IP address of the Instance.status- (Available since v1.248.0) The status of the instance.create_time- (Available since v1.248.0) The time when the instance was created.
Timeouts
-> NOTE: Available since v1.212.0.
The timeouts block allows you to specify timeouts for certain actions:
create- (Defaults to 18 mins) Used when create the Instance.update- (Defaults to 6 mins) Used when update the Instance.delete- (Defaults to 5 mins) Used when delete the Instance.
Import
DdosCoo Instance can be imported using the id, e.g.
$ terraform import alicloud_ddoscoo_instance.example <id>