Add support for 'Endpoint' in Wireguard role
This commit is contained in:
parent
0fbcd687d3
commit
5c7360aded
1 changed files with 5 additions and 2 deletions
|
@ -1,7 +1,6 @@
|
||||||
# {{ ansible_managed }}
|
# {{ ansible_managed }}
|
||||||
|
|
||||||
[Interface]
|
[Interface]
|
||||||
Address = {{ item.addrs | join(",") }}
|
|
||||||
PrivateKey = {{ item.private_key }}
|
PrivateKey = {{ item.private_key }}
|
||||||
ListenPort = {{ item.listen_port }}
|
ListenPort = {{ item.listen_port }}
|
||||||
|
|
||||||
|
@ -9,4 +8,8 @@ ListenPort = {{ item.listen_port }}
|
||||||
[Peer]
|
[Peer]
|
||||||
PublicKey = {{ peer.public_key }}
|
PublicKey = {{ peer.public_key }}
|
||||||
AllowedIps = {{ peer.allowed_addrs | join(", ") }}
|
AllowedIps = {{ peer.allowed_addrs | join(", ") }}
|
||||||
|
PersistentKeepalive = {{ peer.keepalive }}
|
||||||
|
{% if 'endpoint' in peer %}
|
||||||
|
Endpoint = {{ peer.endpoint }}
|
||||||
|
{% endif %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
Loading…
Reference in a new issue