From 9eaca5ae1167b42eff151286f686aa5713070907 Mon Sep 17 00:00:00 2001 From: kjuulh Date: Thu, 24 Feb 2022 14:10:49 +0100 Subject: [PATCH] with correct variables --- infrastructure/create-resources/templates/hosts.tftpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/infrastructure/create-resources/templates/hosts.tftpl b/infrastructure/create-resources/templates/hosts.tftpl index 23a6cb6..ddbe71f 100644 --- a/infrastructure/create-resources/templates/hosts.tftpl +++ b/infrastructure/create-resources/templates/hosts.tftpl @@ -1,11 +1,11 @@ [serverctl_master_hosts] %{ for ip in serverctl_masters ~} -${ip} ansible_host=${ip} wireguard_ip=${cidrhost("192.168.0.0/24", index(serverctl_mesh_nodes, ip) + 1)} +${ip} ansible_host=${ip} wireguard_ip=${cidrhost("192.168.0.0/24", index(serverctl_masters, ip) + 1)} %{ endfor ~} [serverctl_node_hosts] %{ for ip in serverctl_nodes ~} -${ip} ansible_host=${ip} wireguard_ip=${cidrhost("192.168.0.0/24", index(serverctl_mesh_nodes, ip) + 1)} +${ip} ansible_host=${ip} wireguard_ip=${cidrhost("192.168.1.0/24", index(serverctl_nodes, ip) + 1)} %{ endfor ~} [serverctl_cluster:children]