resource "null_resource" "file_provisioners" { depends_on = [ openstack_compute_floatingip_associate_v2.leader, openstack_compute_floatingip_associate_v2.followers ] connection { type = "ssh" host = openstack_networking_floatingip_v2.leader.address user = "ubuntu" agent = false private_key = file(var.private_key_file) } provisioner "file" { source = "leader.tf" destination = "/tmp/leader.tf" } provisioner "file" { content = templatefile("example.tmpl", { fips = openstack_networking_floatingip_v2.followers.*.address }) destination = "follower_fips.txt" } }