alicloud_ddosbgp_instance

更新时间:

Provides a Anti-DDoS Pro (DdosBgp) Instance resource.

For information about Anti-DDoS Pro (DdosBgp) Instance and how to use it, see What is Instance.

-> NOTE: Available since v1.183.0.

Example Usage

Basic Usage


provider "alicloud" {
  region = "cn-hangzhou"
}

variable "name" {
  default = "terraform-example"
}

resource "alicloud_ddosbgp_instance" "instance" {
  name             = var.name
  base_bandwidth   = 20
  bandwidth        = -1
  ip_count         = 100
  ip_type          = "IPv4"
  normal_bandwidth = 100
  type             = "Enterprise"
}

Deleting alicloud_ddosbgp_instance or removing it from your configuration

Terraform cannot destroy resource alicloud_ddosbgp_instance. Terraform will remove this resource from the state file, however resources may remain.

Argument Reference

The following arguments are supported:

  • bandwidth - (Required, ForceNew, Int) The bandwidth of the package configuration.
  • base_bandwidth - (Optional, ForceNew) The basic protection bandwidth of the Anti-DDoS Origin Enterprise instance. Default value: 20. Valid values: 20.
  • instance_name - (Optional, Available since v1.259.0) The name of the instance.
  • ip_count - (Required, ForceNew, Int) The number of IP addresses that can be protected by the Anti-DDoS Origin Enterprise instance.
  • ip_type - (Required, ForceNew) The protection IP address type of the protection package. Valid values:
    • IPv4
    • IPv6
  • normal_bandwidth - (Required, ForceNew, Int) The normal clean bandwidth. Unit: Mbit/s.
  • period - (Optional) The duration that you will buy Ddosbgp instance (in month). Valid values: [1~9], 12, 24, 36. Default to 12. At present, the provider does not support modify "period".
  • resource_group_id - (Optional, Available since v1.259.0) Resource Group ID
  • tags - (Optional, Map, Available since v1.259.0) The key of the tag that is added to the Anti-DDoS Origin instance.
  • type - (Optional, ForceNew) The protection package type of the DDoS native protection instance. Default value: Enterprise. Valid values: Enterprise, Professional.
  • name - (Optional, Deprecated since v1.259.0) Field name has been deprecated from provider version 1.259.0. New field instance_name instead.

Attributes Reference

The following attributes are exported:

  • id - The ID of the resource supplied above.
  • status - (Available since v1.259.0) The status of the Instance.

Timeouts

-> NOTE: Available since v1.259.0.

The timeouts block allows you to specify timeouts for certain actions:

  • create - (Defaults to 26 mins) Used when create the Instance.
  • update - (Defaults to 5 mins) Used when update the Instance.

Import

Anti-DDoS Pro (DdosBgp) Instance can be imported using the id, e.g.

$ terraform import alicloud_ddosbgp_instance.example <id>