文档

alicloud_dcdn_waf_domain

更新时间:
一键部署

Provides a DCDN Waf Domain resource.

For information about DCDN Waf Domain and how to use it, see What is Waf Domain.

-> NOTE: Available since v1.185.0.

Example Usage

Basic Usage

variable "domain_name" {
  default = "tf-example.com"
}

resource "random_integer" "default" {
  min = 10000
  max = 99999
}

resource "alicloud_dcdn_domain" "example" {
  domain_name = "${var.domain_name}-${random_integer.default.result}"
  scope       = "overseas"
  sources {
    content  = "1.1.1.1"
    port     = "80"
    priority = "20"
    type     = "ipaddr"
    weight   = "10"
  }
}

resource "alicloud_dcdn_waf_domain" "example" {
  domain_name   = alicloud_dcdn_domain.example.domain_name
  client_ip_tag = "X-Forwarded-For"
}

Argument Reference

The following arguments are supported:

  • client_ip_tag - (Optional) The client ip tag.
  • domain_name - (Required, ForceNew) The accelerated domain name.

Attributes Reference

The following attributes are exported:

  • id - The resource ID in terraform of Waf Domain. Its value is same as domain_name.

Timeouts

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

  • create - (Defaults to 1 mins) Used when creating the Waf Domain.
  • delete - (Defaults to 1 mins) Used when deleting the Waf Domain.
  • update - (Defaults to 1 mins) Used when updating the Waf Domain.

Import

DCDN Waf Domain can be imported using the id, e.g.

$ terraform import alicloud_dcdn_waf_domain.example <domain_name>

  • 本页导读 (0)
文档反馈