serverctl/infrastructure/create-resources/templates/hosts.tftpl

19 lines
509 B
Plaintext
Raw Normal View History

2022-02-24 13:57:19 +01:00
[serverctl_master_hosts]
%{ for ip in serverctl_masters ~}
2022-02-24 14:09:13 +01:00
${ip} ansible_host=${ip} wireguard_ip=${cidrhost("192.168.0.0/24", index(serverctl_mesh_nodes, ip) + 1)}
2022-02-24 13:57:19 +01:00
%{ 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)}
%{ endfor ~}
[serverctl_cluster:children]
serverctl_master_hosts
serverctl_node_hosts
2022-02-24 14:09:13 +01:00
[serverctl_cluster:vars]
pipelining=true
ansible_ssh_user=root
ansible_ssh_port=22