alicloud_message_service_endpoint_acl

更新时间:

Provides a Message Service Endpoint Acl resource.

For information about Message Service Endpoint Acl and how to use it, see What is Endpoint Acl.

-> NOTE: Available since v1.243.0.

Example Usage

Basic Usage


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

resource "alicloud_message_service_endpoint" "default" {
  endpoint_enabled = true
  endpoint_type    = "public"
}

resource "alicloud_message_service_endpoint_acl" "default" {
  cidr          = "192.168.1.1/23"
  endpoint_type = alicloud_message_service_endpoint.default.id
  acl_strategy  = "allow"
}

Argument Reference

The following arguments are supported:

  • acl_strategy - (Required, ForceNew) The ACL policy. Valid value:
    • allow: indicates that the current endpoint allows access from the corresponding CIDR block. (Only allow is supported)
  • cidr - (Required, ForceNew) The CIDR block. -> NOTE: To ensure business stability, the system is configured by default with a CIDR (0.0.0.0/0) that allows access from all source addresses. If you need to remove this default configuration, you can do so by importing and deleting the CIDR using Terraform, or by manually deleting it in the console.
  • endpoint_type - (Required, ForceNew) Access point type. Value:
    • public: indicates a public access point. (Currently only public is supported)

Attributes Reference

The following attributes are exported:

  • id - The resource ID in terraform of Endpoint Acl. It formats as <endpoint_type>:<acl_strategy>:<cidr>.

Timeouts

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

  • create - (Defaults to 5 mins) Used when create the Endpoint Acl.
  • delete - (Defaults to 5 mins) Used when delete the Endpoint Acl.

Import

Message Service Endpoint Acl can be imported using the id, e.g.

$ terraform import alicloud_message_service_endpoint_acl.example <endpoint_type>:<acl_strategy>:<cidr>