Created
February 3, 2021 03:57
-
-
Save Craigson/38e548d9fb3a7e4a84acb9c3448d2faa to your computer and use it in GitHub Desktop.
A section of the Terraform template file for creating the Ansible Inventory
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[digitalocean] | |
%{ for index, ip in droplet_ips ~} | |
${droplet_names[index]} ansible_host=${ip} ansible_connection=ssh ansible_user=root subnet=172.${sort(droplet_host_numbers[index])[0]}.0.0/24 ipfs_host=172.${sort(droplet_host_numbers[index])[0]}.0.2 | |
%{ endfor ~} | |
[digitalocean:vars] | |
agent_provider="6" | |
agent_tags="digitalocean" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment