Skip to content

Latest commit

 

History

History
73 lines (53 loc) · 1.06 KB

File metadata and controls

73 lines (53 loc) · 1.06 KB

vsphere_datacenter

back

Index

Terraform

terraform {
  required_providers {
    vsphere = ">= 1.25.0"
  }
}

top

Example Usage

module "vsphere_datacenter" {
  source = "./modules/vsphere/d/vsphere_datacenter"

  # name - (optional) is a type of string
  name = null
}

top

Variables

variable "name" {
  description = "(optional) - The name of the datacenter. This can be a name or path.\tCan be omitted if there is only one datacenter in your inventory."
  type        = string
  default     = null
}

top

Datasource

data "vsphere_datacenter" "this" {
  # name - (optional) is a type of string
  name = var.name
}

top

Outputs

output "id" {
  description = "returns a string"
  value       = data.vsphere_datacenter.this.id
}

output "this" {
  value = vsphere_datacenter.this
}

top