Skip to content

Latest commit

 

History

History
97 lines (74 loc) · 1.79 KB

vsphere_vmfs_disks.md

File metadata and controls

97 lines (74 loc) · 1.79 KB

vsphere_vmfs_disks

back

Index

Terraform

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

top

Example Usage

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

  # filter - (optional) is a type of string
  filter = null
  # host_system_id - (required) is a type of string
  host_system_id = null
  # rescan - (optional) is a type of bool
  rescan = null
}

top

Variables

variable "filter" {
  description = "(optional) - A regular expression to filter the disks against. Only disks with canonical names that match will be included."
  type        = string
  default     = null
}

variable "host_system_id" {
  description = "(required) - The managed object ID of the host to search for disks on."
  type        = string
}

variable "rescan" {
  description = "(optional) - Rescan the system for disks before querying. This may lengthen the time it takes to gather information."
  type        = bool
  default     = null
}

top

Datasource

data "vsphere_vmfs_disks" "this" {
  # filter - (optional) is a type of string
  filter = var.filter
  # host_system_id - (required) is a type of string
  host_system_id = var.host_system_id
  # rescan - (optional) is a type of bool
  rescan = var.rescan
}

top

Outputs

output "disks" {
  description = "returns a list of string"
  value       = data.vsphere_vmfs_disks.this.disks
}

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

output "this" {
  value = vsphere_vmfs_disks.this
}

top