saltext.vcf.utils.cim

ESXi CIM/WBEM connection helpers (pywbem).

ESXi hosts expose hardware health (fans, PSUs, RAID controllers, sensors) via a CIM/WBEM endpoint on port 5989 (HTTPS) or 5988 (HTTP). This is the only programmatic path for out-of-band hardware health — the vSphere API does not expose this data.

Config is read from Salt opts/pillar under saltext.vcf.esxi — same pillar block as the standalone ESXi REST modules:

saltext.vcf:
  esxi:
    host: esxi01.example.com
    username: root
    password: VMware123!
    verify_ssl: false
    cim_port: 5989       # optional; default 5989
saltext.vcf.utils.cim.get_config(opts, profile=None)[source]

CIM shares the ESXi pillar block. Adds a cim_port field.

saltext.vcf.utils.cim.get_connection(opts, profile=None)[source]

Return a connected pywbem.WBEMConnection.

Cached per (host, username). The connection talks to the ESXi host’s SFCB CIM provider at https://host:5989.