Resources

zsphere_datacenter

This resource allows you to manage datacenters (zones) in ZSvirt. A datacenter (zone) is a logical container that groups compute resources like clusters and hosts. It provides resource isolation and can be used to organize infrastructure for different environments or tenants.

zsphere_datacenter (Resource)

This resource allows you to manage datacenters (zones) in ZSvirt. A datacenter (zone) is a logical container that groups compute resources like clusters and hosts. It provides resource isolation and can be used to organize infrastructure for different environments or tenants.

Example Usage

resource "zsphere_datacenter" "datacenter" {
  name        = "datacenter_from_terraform"
  description = "Add an example datacenter from terraform"
  is_default  = false
}

output "zsphere_datacenter" {
  value = zsphere_datacenter.datacenter
}

Schema

Required

  • name (String) The name of the datacenter. This is a mandatory field.

Optional

  • description (String) A description of the datacenter, providing additional context or details.
  • is_default (Boolean) Indicates if this is the default datacenter. Only one datacenter can be the default.

Read-Only

  • state (String) The state of the datacenter, such as 'Enabled' or 'Disabled'.
  • type (String) The type of the datacenter. Currently only 'zstack' is supported.
  • uuid (String) The unique identifier of the datacenter. Automatically generated by ZSvirt.

On this page