You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
UPDATE: just realized that your README does not mention the post on your website; can it be updated to link to the original post?
The example is currently hardcoded with a string of fake IPs. Could a real-world example also be provided, i.e. using data from an actual resource (DigitalOcean/AWS, etc.)?
I have been trying to modify the outputs.tf file as follows, however it only outputs the first generated IP from the resource:
data "template_file" "ansible_hosts" {
template = "${file("ansible_hosts.tpl")}"
vars {
# This works for first IP
do_hosts = "Instances: ${element(digitalocean_droplet.host.*.ipv4_address, count.index)}"
}
}
output "ansible_hosts" {
value = "${data.template_file.ansible_hosts.rendered}"
}
UPDATE: just realized that your README does not mention the post on your website; can it be updated to link to the original post?
The example is currently hardcoded with a string of fake IPs. Could a real-world example also be provided, i.e. using data from an actual resource (DigitalOcean/AWS, etc.)?
I have been trying to modify the
outputs.tf
file as follows, however it only outputs the first generated IP from the resource:For reference, here is my resource:
The text was updated successfully, but these errors were encountered: