alicloud_click_house_enterprise_db_cluster_public_endpoint

更新时间:2025-04-24 13:15:51

Provides a Click House Enterprise Db Cluster Public Endpoint resource.

ClickHouse enterprise instance public network endpoint.

For information about Click House Enterprise Db Cluster Public Endpoint and how to use it, see What is Enterprise Db Cluster Public Endpoint.

-> NOTE: Available since v1.247.0.

Example Usage

Basic Usage


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

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

variable "region_id" {
  default = "cn-beijing"
}

variable "vsw_ip_range_i" {
  default = "172.16.1.0/24"
}

variable "vpc_ip_range" {
  default = "172.16.0.0/12"
}

variable "zone_id_i" {
  default = "cn-beijing-i"
}

resource "alicloud_vpc" "defaultktKLuM" {
  cidr_block = var.vpc_ip_range
}

resource "alicloud_vswitch" "defaultTQWN3k" {
  vpc_id     = alicloud_vpc.defaultktKLuM.id
  zone_id    = var.zone_id_i
  cidr_block = var.vsw_ip_range_i
}

resource "alicloud_click_house_enterprise_db_cluster" "defaultaqnt22" {
  zone_id    = var.zone_id_i
  vpc_id     = alicloud_vpc.defaultktKLuM.id
  scale_min  = "8"
  scale_max  = "16"
  vswitch_id = alicloud_vswitch.defaultTQWN3k.id
}


resource "alicloud_click_house_enterprise_db_cluster_public_endpoint" "default" {
  db_instance_id           = alicloud_click_house_enterprise_db_cluster.defaultaqnt22.id
  net_type                 = "Public"
  connection_string_prefix = alicloud_click_house_enterprise_db_cluster.defaultaqnt22.id
}

Argument Reference

The following arguments are supported:

  • connection_string_prefix - (Required) The public network connection string prefix of the instance.
  • db_instance_id - (Required, ForceNew) The cluster ID.
  • net_type - (Required, ForceNew) Network type of the connection address. Valid values:
    • Public: Public network.

Attributes Reference

The following attributes are exported:

  • id - The ID of the resource supplied above.The value is formulated as <db_instance_id>:<net_type>.

Timeouts

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

  • create - (Defaults to 5 mins) Used when create the Enterprise Db Cluster Public Endpoint.
  • delete - (Defaults to 5 mins) Used when delete the Enterprise Db Cluster Public Endpoint.
  • update - (Defaults to 5 mins) Used when update the Enterprise Db Cluster Public Endpoint.

Import

Click House Enterprise Db Cluster Public Endpoint can be imported using the id, e.g.

$ terraform import alicloud_click_house_enterprise_db_cluster_public_endpoint.example <db_instance_id>:<net_type>

  • 本页导读 (1)
  • Example Usage
  • Argument Reference
  • Attributes Reference
  • Timeouts
  • Import