Refactor Wireguard media setup like a777228013

This commit is contained in:
sonny 2025-03-01 20:27:16 +01:00
parent a777228013
commit 63c164ac4b
6 changed files with 70 additions and 77 deletions

View file

@ -7,12 +7,12 @@ Description=WireGuard tunnel wg1
[WireGuard]
ListenPort={{ vpn_media_port }}
PrivateKey={{ vpn_media_server_key }}
PrivateKeyFile={{ vpn_media_server_key_path }}
{% for peer, properties in vpn_media_peers.items() %}
[WireGuardPeer]
PublicKey={{ properties.public_key }}
PresharedKey={{ properties.preshared_key }}
PresharedKeyFile={{ properties.preshared_key_path }}
AllowedIPs={{ properties.ip }}/32
{% if not loop.last %}