Reputation: 29
I am looking to take full advantage of the recently introduce pyvmomi module to further management and I would like to remove the use of ssh and convert utility calls through the API; Is this possible?
Upvotes: 3
Views: 5102
Reputation: 337
Sorry for the slow reply! I found your Q looking for some info on this myself. In vSphere 5 and above there is a provision to run commands as long as you are a registered user on the system (and can abide by the authentication mechanisms).
If you are a Pythonista life is going to get semi-easy for you! There is a beautiful module called Pyvmomi - https://github.com/vmware/pyvmomi
This allows easy communication with the API of vSphere.
The steps are:
There are many samples in the community samples page at https://github.com/vmware/pyvmomi-community-samples that will wet your apitite!
I have tried getting this functionality in lower versions of vSphere but found I really had to abuse the console API - sadly that code has become propriety now so I cannot share :-(
Happy Automating! //P
Upvotes: 0