diff --git a/ansible/inventories/README.md b/ansible/inventories/README.md new file mode 100644 index 0000000..6fc5e90 --- /dev/null +++ b/ansible/inventories/README.md @@ -0,0 +1,16 @@ +# Inventory gets from VMVare vSphere + +
+
+Add it to you Ansible config file ( /root/.ansible.cfg ):
+
+`[inventory]`
+`enable_plugins = host_list, script, auto, yaml, ini, toml, community.vmware.vmware_vm_inventory`
+
+
+For use:
+
+`ansible-inventory -i /root/ansible/inventories/vmware_vm_inventory.yml --list -y --output zzz.yml`
+`cat zzz.yml | grep -i "guestid" | sed 's/^ config.guestId: //' | sed 's/$.*//' | sort | uniq`
+
+