community.vmware
community.vmware copied to clipboard
vmware_guest_info - remove dependency on Datacenter
SUMMARY
vmware_guest_info modules has a mandatory parameter Datacenter It gets tricky in large environments to get information about the VM where I need to use multiple modules first need to run module to figure out in which Datacenter the VM is located. here i use vm_find module which in our environment with 5000+ VMs is super slow - takes minutes to complete the job second to run this module to grab VM details
ISSUE TYPE
- Feature Idea It would be great to have Datacenter manatory param removed if possible especially when using VM moid to search for VM moid is a global unique parameter where Datacenter name should really not be required ?
COMPONENT NAME
vmware_guest_info
ADDITIONAL INFORMATION
+1 for this It really makes no sense to have the datacenter parameter required considering that the module that actually creates VMs doesn't require it all. Even the one that manages the powerstate of a VM doesn't require. But the one that makes no changes and is a readonly operation requires it. Makes absolutely no sense. Really weird.
+1 cannot do automation with multiple datacenter like take snapshots. I t would be great if it can be removed from requirement.
+1 There should be no requirement for datacenter. But: Throw an error, if you find more than one VM, which might happen if you look fo a VM via display name. If you identify a VM via moid, then it should definitely work without datacenter info.