On Windows, you must install Python 3.7.1 or later with the required packages and configure PowerCLI to use the VMware.ImageBuilder module.
Procedure
- Download Python 3.7.1 or later from https://www.python.org/downloads and complete the installation on your machine.
- Save the get-pip.py file from https://bootstrap.pypa.io/get-pip.py.
- Open a terminal and install pip package manager.
<pythonVer-directory>\python.exe <get-pip-directory>\get-pip.py
For example:
<python3.10-directory>\python.exe <get-pip-directory>\get-pip.py
- In the terminal, install the required Python modules.
<pythonVer-directory>\Scripts\pip<Version>.exe install six psutil lxml pyopenssl
For example:
<python3.10-directory>\Scripts\pip3.10.exe install six psutil lxml pyopenssl
- Open PowerShell and set the path to the Python executable.
Set-PowerCLIConfiguration -PythonPath <pythonVer-directory>\python.exe -Scope User
For example:
Set-PowerCLIConfiguration -PythonPath <python3.10-directory>\python.exe -Scope User
Results
You can now use the
PowerCLI
VMware.ImageBuider module.