vmware-archive / nsxansible

A set of example Ansible Modules using the above two projects as the basis
Other
109 stars 71 forks source link

No virtualmachine_name parameter in vcenter_gather_moids module #54

Open ColinJao opened 7 years ago

ColinJao commented 7 years ago

In nsx_attach_vm_switch.py method, we need to input the "gather_uuid_vm.object_uuid" parameter, which are output from the vcenter_gather_moids.py method, and "virtualmachine_name" needs to be an parameter as input.

https://github.com/vmware/nsxansible/blob/master/test_vmmigrate.yml

However by running above playbook, the error message will shown as:

fatal: [10.9.24.181]: FAILED! => {"changed": false, "failed": true, "msg": "Unsupported parameters for (vcenter_gather_moids) module: virtualmachine_name. Supported parameters include: cluster_name,datacenter_name,datastore_name,dvs_name,hostname,password,portgroup_name,resourcepool_name,username,validate_certs"}

Which said no "virtualmachine_name" parameter is supported in vcenter_gather_moids module.

2017-06-03 00 07 20
shinesemigod commented 6 years ago

https://gist.github.com/sky-joker/b894e2f1bcdf4f9e6a966c91f745b492 FYI. It works to me.