change: Add outputs for all worker nodes as well

This commit is contained in:
2025-08-03 15:21:17 +02:00
parent 0a851ca2aa
commit 8a4f2c6e1c
2 changed files with 16 additions and 0 deletions
@@ -9,3 +9,15 @@ output "node_details" {
} }
} }
} }
output "worker_node_details" {
value = {
for idx, instance in hcloud_server.worker_node :
"worker-node-${idx}" => {
id = instance.id
name = instance.name
ipv4 = instance.ipv4_address
ipv6 = instance.ipv6_address
}
}
}
+4
View File
@@ -10,3 +10,7 @@
output "swarm_nodes" { output "swarm_nodes" {
value = module.test_swarm_cluster.node_details value = module.test_swarm_cluster.node_details
} }
output "swarm_worker_nodes" {
value = module.test_swarm_cluster.worker_node_details
}