summaryrefslogtreecommitdiff
path: root/inventory/host_vars/ele-gwhetzner.yml
diff options
context:
space:
mode:
Diffstat (limited to 'inventory/host_vars/ele-gwhetzner.yml')
-rw-r--r--inventory/host_vars/ele-gwhetzner.yml10
1 files changed, 6 insertions, 4 deletions
diff --git a/inventory/host_vars/ele-gwhetzner.yml b/inventory/host_vars/ele-gwhetzner.yml
index 2519ab94..b85b5243 100644
--- a/inventory/host_vars/ele-gwhetzner.yml
+++ b/inventory/host_vars/ele-gwhetzner.yml
@@ -23,12 +23,14 @@ network:
domain: "{{ host_domain }}"
systemd_link:
interfaces: "{{ install.interfaces }}"
- primary:
- interface: primary0
+ primary: &_network_primary_
+ name: primary0
ip: "{{ hostvars[_vm_host_].vm_host.network.bridges.public.prefix | ipaddr(hostvars[_vm_host_].vm_host.network.bridges.public.offsets[inventory_hostname]) | ipaddr('address') }}"
mask: "{{ hostvars[_vm_host_].vm_host.network.bridges.public.prefix | ipaddr('netmask') }}"
gateway: "{{ hostvars[_vm_host_].vm_host.network.bridges.public.prefix | ipaddr('address') }}"
overlay: "{{ (hostvars[_vm_host_].vm_host.network.bridges.public.overlay.prefix | ipaddr(hostvars[_vm_host_].vm_host.network.bridges.public.overlay.offsets[inventory_hostname])).split('/')[0] }}"
+ interfaces:
+ - *_network_primary_
external_ip: "{{ network.primary.overlay }}"
@@ -48,7 +50,7 @@ wireguard_gateway_tunnels:
addresses:
- 192.168.254.1/30
ip_snat:
- interface: "{{ network.primary.interface }}"
+ interface: "{{ network.primary.name }}"
to: "{{ network.primary.overlay }}"
port_forwardings:
- dest: "{{ network.primary.overlay }}"
@@ -67,7 +69,7 @@ wireguard_gateway_tunnels:
addresses:
- 192.168.254.5/30
ip_snat:
- interface: "{{ network.primary.interface }}"
+ interface: "{{ network.primary.name }}"
to: "{{ network.primary.overlay }}"
port_forwardings:
- dest: "{{ network.primary.overlay }}"