alicloud_ens_snapshot

更新时间:

Provides a ENS Snapshot resource. Snapshot. When you use it for the first time, please contact the product classmates to add a resource whitelist.

For information about ENS Snapshot and how to use it, see What is Snapshot.

-> NOTE: Available since v1.213.0.

Example Usage

Basic Usage


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

resource "alicloud_ens_disk" "disk" {
  category      = "cloud_efficiency"
  size          = "20"
  payment_type  = "PayAsYouGo"
  ens_region_id = "ch-zurich-1"
}

resource "alicloud_ens_snapshot" "default" {
  description   = var.name
  ens_region_id = "ch-zurich-1"
  snapshot_name = var.name

  disk_id = alicloud_ens_disk.disk.id
}

Argument Reference

The following arguments are supported:

  • description - (Optional) Snapshot Description Information.
  • disk_id - (Required, ForceNew) Cloud Disk ID.
  • ens_region_id - (Required, ForceNew) The node ID of ENS.
  • snapshot_name - (Optional) Name of the snapshot instance.

Attributes Reference

The following attributes are exported:

  • id - The ID of the resource supplied above.
  • create_time - Instance creation timeIt is expressed in accordance with the ISO8601 standard and uses UTC +0 time in the format of yyyy-MM-ddTHH:mm:ssZ.Example value: 2020-08-20 T14:52:28Z.
  • status - Snapshot Status. Valid values: creating, available, deleting, error.

Timeouts

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

  • create - (Defaults to 5 mins) Used when create the Snapshot.
  • delete - (Defaults to 5 mins) Used when delete the Snapshot.
  • update - (Defaults to 5 mins) Used when update the Snapshot.

Import

ENS Snapshot can be imported using the id, e.g.

$ terraform import alicloud_ens_snapshot.example <id>