A simple command line interface for common VMware vSphere tasks.
EZmomi uses pyvmomi (VMware vSphere API Python Bindings).
pip install ezmomi
ezmomi clone --template centos65 --hostname test01 --cpus 2 --mem 4 --ips 172.10.16.203 172.10.16.204
ips
takes any number of ips. See ezmomi clone --help
for a list of params.
Guest shutdown
ezmomi shutdown --name test01
This command falls back to powerOff if VMware guest tools are not installed/available.
Power On/Off
ezmomi powerOn --name test01
ezmomi powerOff --name test01
ezmomi status --name test01
ezmomi destroy --name test01
ezmomi list --type VirtualMachine
ezmomi list --type Network
ezmomi list --type Datastore
etc...
See Managed Object Types in the vSphere API docs for a list of types to look up.
Each command section has its own help:
ezmomi --help
ezmomi clone --help
ezmomi list --help
etc...
git clone [email protected]:snobear/ezmomi.git
virtualenv --no-site-packages ezmomi
cd ezmomi && source bin/activate
pip install -r requirements.txt
export PYTHONPATH=$PWD:$PYTHONPATH
ezmomi --help
Pull requests, bug reports, and feature requests are extremely welcome.