Closed zengyijian916 closed 1 year ago
I have changed the task as below:
[root@Orchestrator upi]# cat roles/vmware/tasks/main.yml
name: Check if the vCenter folder already exists command: argv:
name: Create the vCenter folder by the same name as the cluster, only if it doesn't exist command: argv:
and if manually create the folder, this command will successfully. [root@Orchestrator upi]# govc folder.create /vsphere.com/vm/ocp4-pv8q7
Can you explain a little bit more about it
Closing due to no updates from original poster. I have not heard of issues around folder creation. Please open a new issue if still having issues.
TASK [common : Display the absolute folder path of the vCenter folder] *** skipping: [localhost]
PLAY [localhost] *****
TASK [vmware : Check if the vCenter folder already exists] *** fatal: [localhost]: FAILED! => {"changed": false, "cmd": "'govc folder.info /vsphere.com/vm/ocp4-t4kb5'", "msg": "[Errno 2] No such file or directory: b'govc folder.info /vsphere.com/vm/ocp4-t4kb5': b'govc folder.info /vsphere.com/vm/ocp4-t4kb5'", "rc": 2} ...ignoring
TASK [vmware : Create the vCenter folder by the same name as the cluster, only if it doesn't exist] *** fatal: [localhost]: FAILED! => {"changed": false, "cmd": "'govc folder.create /vsphere.com/vm/ocp4-t4kb5'", "msg": "[Errno 2] No such file or directory: b'govc folder.create /vsphere.com/vm/ocp4-t4kb5': b'govc folder.create /vsphere.com/vm/ocp4-t4kb5'", "rc": 2}
PLAY RECAP *** localhost : ok=33 changed=12 unreachable=0 failed=1 skipped=12 rescued=0 ignored=1
[root@Orchestrator upi]#