mirror of
https://github.com/fscotto/infra.git
synced 2026-09-27 19:03:47 +00:00
Move WireGuard gateway to Aegis
This commit is contained in:
@@ -11,7 +11,8 @@ ListenPort = {{ wireguard_listen_port }}
|
||||
{% for peer in wireguard_peers %}
|
||||
[Peer]
|
||||
# {{ peer.name }}
|
||||
PublicKey = {{ hostvars[peer.host].wireguard_public_key }}
|
||||
{% if peer.comment is defined %}# {{ peer.comment }}
|
||||
{% endif %}PublicKey = {{ hostvars[peer.host].wireguard_public_key }}
|
||||
AllowedIPs = {{ peer.allowed_ips | join(', ') }}
|
||||
{% if peer.endpoint is defined %}
|
||||
Endpoint = {{ peer.endpoint }}
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<policy target="CONTINUE">
|
||||
<short>WireGuard forwarding: {{ item.name }}</short>
|
||||
<description>Managed WireGuard-to-LAN forwarding policy.</description>
|
||||
{% if item.masquerade | default(false) %}
|
||||
<masquerade/>
|
||||
{% endif %}
|
||||
<ingress-zone name="{{ item.ingress_zone }}"/>
|
||||
<egress-zone name="{{ item.egress_zone }}"/>
|
||||
<rule family="ipv4">
|
||||
<source address="{{ item.source }}"/>
|
||||
<destination address="{{ item.destination }}"/>
|
||||
<accept/>
|
||||
</rule>
|
||||
</policy>
|
||||
Reference in New Issue
Block a user