alicloud_esa_waiting_room_event

更新时间:

Provides a ESA Waiting Room Event resource.

For information about ESA Waiting Room Event and how to use it, see What is Waiting Room Event.

-> NOTE: Available since v1.244.0.

Example Usage

Basic Usage


data "alicloud_esa_sites" "default" {
  plan_subscribe_type = "enterpriseplan"
}

resource "alicloud_esa_site" "default" {
  site_name   = "chenxin0116.site"
  instance_id = data.alicloud_esa_sites.default.sites.0.instance_id
  coverage    = "overseas"
  access_type = "NS"
}

resource "alicloud_esa_waiting_room" "default" {
  status                         = "off"
  site_id                        = alicloud_esa_site.default.id
  json_response_enable           = "off"
  description                    = "example"
  waiting_room_type              = "default"
  disable_session_renewal_enable = "off"
  cookie_name                    = "__aliwaitingroom_example"
  waiting_room_name              = "waitingroom_example"
  queue_all_enable               = "off"
  queuing_status_code            = "200"
  custom_page_html               = ""
  new_users_per_minute           = "200"
  session_duration               = "5"
  language                       = "zhcn"
  total_active_users             = "300"
  queuing_method                 = "fifo"
  host_name_and_path {
    domain    = "sub_domain.com"
    path      = "/example"
    subdomain = "example_sub_domain.com."
  }
}

resource "alicloud_esa_waiting_room_event" "default" {
  waiting_room_id                = alicloud_esa_waiting_room.default.waiting_room_id
  end_time                       = "1719863200"
  waiting_room_event_name        = "WaitingRoomEvent_example"
  pre_queue_start_time           = ""
  random_pre_queue_enable        = "off"
  json_response_enable           = "off"
  site_id                        = alicloud_esa_site.default.id
  pre_queue_enable               = "off"
  description                    = "example"
  new_users_per_minute           = "200"
  queuing_status_code            = "200"
  custom_page_html               = ""
  language                       = "zhcn"
  total_active_users             = "300"
  waiting_room_type              = "default"
  start_time                     = "1719763200"
  status                         = "off"
  disable_session_renewal_enable = "off"
  queuing_method                 = "fifo"
  session_duration               = "5"
}

Argument Reference

The following arguments are supported:

  • custom_page_html - (Optional) User-defined waiting room page content, when the waiting room type is custom type, you need to enter. The incoming content needs to be base64 encoded.
  • description - (Optional) Waiting room description.
  • disable_session_renewal_enable - (Optional) Disable session renewal. Value: -'on': open. -'off': closed.
  • end_time - (Required) The timestamp of the end time of the event.
  • json_response_enable - (Optional) JSON response switch. Value: -'on': open. -'off': closed.
  • language - (Optional) Default language setting. Values include: -'enus': English. -'zhcn': Simplified Chinese. -'zhhk': Traditional Chinese.
  • new_users_per_minute - (Required) Number of new users per minute.
  • pre_queue_enable - (Optional) Pre-queue switch. -'on': open. -'off': closed.
  • pre_queue_start_time - (Optional) Pre-queue start time.
  • queuing_method - (Required) Way of queuing. Value: -'random': random. -'fifo': first in, first out. -'passthrough ': through. -'reject-all': reject all.
  • queuing_status_code - (Required) Waiting room status code. Value: -'200' -'202' -'429'
  • random_pre_queue_enable - (Optional) Random queue switch. -'on': open. -'off': closed.
  • session_duration - (Required) User session duration in minutes.
  • site_id - (Required, ForceNew, Int) The site ID, which can be obtained by calling the ListSites API.
  • start_time - (Required) The timestamp of the event start time.
  • status - (Required) Enabled status. Value: -'on': Enable waiting room events -'off': Disable waiting room events
  • total_active_users - (Required) Total number of active users.
  • waiting_room_event_name - (Required) Event name, custom event description.
  • waiting_room_id - (Optional, ForceNew, Computed) Waiting room ID, used to identify a specific waiting room. It can be obtained by calling the listwaitingroom interface.
  • waiting_room_type - (Required) Waiting room type. The following types are supported: -'default': the default type. -'custom': custom type.

Attributes Reference

The following attributes are exported:

  • id - The ID of the resource supplied above.The value is formulated as <site_id>:<waiting_room_id>:<waiting_room_event_id>.
  • waiting_room_event_id - The waiting room event ID, which can be obtained by calling the ListWaitingRoomEvents operation.

Timeouts

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

  • create - (Defaults to 5 mins) Used when create the Waiting Room Event.
  • delete - (Defaults to 5 mins) Used when delete the Waiting Room Event.
  • update - (Defaults to 5 mins) Used when update the Waiting Room Event.

Import

ESA Waiting Room Event can be imported using the id, e.g.

$ terraform import alicloud_esa_waiting_room_event.example <site_id>:<waiting_room_id>:<waiting_room_event_id>