2024-09-29 18:04:34 +05:00
|
|
|
[Interface]
|
|
|
|
PrivateKey = {{ private_key.content | b64decode }}
|
2024-10-30 17:42:17 +05:00
|
|
|
Address = {{ address }}
|
|
|
|
ListenPort = {{ listen_port }}
|
|
|
|
PostUp = iptables -A FORWARD -i %i -j ACCEPT; iptables -t nat -A POSTROUTING -o {{ interface }} -j MASQUERADE
|
|
|
|
PostDown = iptables -D FORWARD -i %i -j ACCEPT; iptables -t nat -D POSTROUTING -o {{ interface }} -j MASQUERADE
|
2024-09-29 18:04:34 +05:00
|
|
|
|
2024-10-30 17:42:17 +05:00
|
|
|
{% for peer in peers %}
|
2024-09-29 18:04:34 +05:00
|
|
|
[Peer]
|
2024-10-30 17:42:17 +05:00
|
|
|
PublicKey = {{ peer.public_key }}
|
|
|
|
AllowedIPs = {{ peer.allowed_ips }}
|
|
|
|
{% endfor %}
|