ansible/roles/wireguard-endpoint/templates/wireguard.conf.j2

12 lines
282 B
Django/Jinja

# {{ ansible_managed }}
[Interface]
Address = {{ item.addrs | join(",") }}
PrivateKey = {{ item.private_key }}
ListenPort = {{ item.listen_port }}
{% for peer in item.peers %}
[Peer]
PublicKey = {{ peer.public_key }}
AllowedIps = {{ peer.allowed_addrs | join(",") }}
{% endfor %}