Skip to main content

vsphere

Supported Platform

  • vmware-esxi
  • vmware-vsphere

Description

VMware vSphere resource

Fields

IDTYPEDESCRIPTION
aboutdictsystem information including the name, type, version, and build number
licenses[]vsphere.licenseconfigured licenses
datacenters[]vsphere.datacenterlist of available datacenter

Examples

Display Information about the vSphere environment

vsphere.about;

Display ESXi host moid and properties

vsphere.datacenters { hosts { moid properties } }

Display NTP server for all ESXi hosts

vsphere.datacenters { hosts { ntp.server } }

Ensure a specific NTP Server is set

vsphere.datacenters { hosts { ntp.server.any(_ == "10.31.21.2") } }

Ensure specific VmkNics properties for all management VmkNics

vsphere.datacenters {
hosts {
vmknics.where(tags == "Management") {
properties['Enabled'] == true
properties['MTU'] == 1500
properties['VDSName'] != /(?i)storage/
}
}
}