alicloud_ecs_deployment_set

更新时间:

Provides a ECS Deployment Set resource.

For information about ECS Deployment Set and how to use it, see What is Deployment Set.

-> NOTE: Available since v1.140.0.

Example Usage

Basic Usage


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

resource "alicloud_ecs_deployment_set" "default" {
  strategy            = "Availability"
  deployment_set_name = var.name
  description         = var.name
}

Argument Reference

The following arguments are supported:

  • strategy - (Optional, ForceNew) The deployment strategy. Default value: Availability. Valid values: Availability, AvailabilityGroup, LowLatency.
  • deployment_set_name - (Optional) The name of the deployment set. The name must be 2 to 128 characters in length and can contain letters, digits, colons (:), underscores (_), and hyphens (-). It must start with a letter and cannot start with http:// or https://.
  • description - (Optional) The description of the deployment set. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
  • on_unable_to_redeploy_failed_instance - (Optional) The emergency solution to use in the situation where instances in the deployment set cannot be evenly distributed to different zones due to resource insufficiency after the instances failover. Valid values:
    • CancelMembershipAndStart - Removes the instances from the deployment set and starts the instances immediately after they are failed over.
    • KeepStopped- Leaves the instances in the Stopped state and starts them after resources are replenished.
  • domain - (Deprecated since v1.243.0) Field domain has been deprecated from provider version 1.243.0.
  • granularity - (Deprecated since v1.243.0) Field granularity has been deprecated from provider version 1.243.0.

Attributes Reference

The following attributes are exported:

  • id - The resource ID in terraform of Deployment Set.

Import

ECS Deployment Set can be imported using the id, e.g.

$ terraform import alicloud_ecs_deployment_set.example <id>