Open queglay opened 5 years ago
You can accomplish this by creating a script in the inventory folder that invokes terraform-inventory.
Here's an example that uses both terraform-inventory and a static inventory: https://github.com/DMarby/infrastructure/blob/master/ansible.cfg#L7 https://github.com/DMarby/infrastructure/tree/eb44681595a093a11b4d879e202ce08a496d06fb/ansible/inventory
Thanks, that's cool you can point it at a specific tfstate file.
Are there suggested best practices for combining multiple inventories with this tool?
I was reading this blog post about how to combine multiple inventories with similar tools to terraform-inventory. It suggests to point your inventory to a folder, and multiple inventory files will be combined. I'm not sure if its possible to do it here though, because terraform-inventory is an executable.
http://allandenot.com/devops/2015/01/16/ansible-with-multiple-inventory-files.html