diff options
author | Christian Pointner <equinox@spreadspace.org> | 2020-06-22 02:37:11 +0200 |
---|---|---|
committer | Christian Pointner <equinox@spreadspace.org> | 2020-06-22 02:37:11 +0200 |
commit | 5a35c210ddb64998586b69b921e8d721395f09d5 (patch) | |
tree | 9a65e26f147c59ab379e1cd23a1baf60ac5d5264 /roles/elevate/media/templates | |
parent | Merge branch 'topic/kubernetes-network-plugins' (diff) | |
parent | converted other physical machines to new network config (diff) |
Merge branch 'topic/network-interfaces-variables-refactoring'
Diffstat (limited to 'roles/elevate/media/templates')
10 files changed, 22 insertions, 22 deletions
diff --git a/roles/elevate/media/templates/firewall/elevate-festival.sh.j2 b/roles/elevate/media/templates/firewall/elevate-festival.sh.j2 index fbd1ad4f..c9d6cb88 100644 --- a/roles/elevate/media/templates/firewall/elevate-festival.sh.j2 +++ b/roles/elevate/media/templates/firewall/elevate-festival.sh.j2 @@ -15,9 +15,9 @@ MANGLE="$IPTABLES -t mangle" FILTER6="$IP6TABLES -t filter" MANGLE6="$IP6TABLES -t mangle" -LAN_IF="{{ network.primary.interface }}" -LAN_IPADDR="{{ network.primary.ip }}" -LAN_NETMASK="{{ network.primary.mask }}" +LAN_IF="{{ network.primary.name }}" +LAN_IPADDR="{{ network.primary.address | ipaddr('address') }}" +LAN_NETMASK="{{ network.primary.address | ipaddr('netmask') }}" EXT_IF="wg-gwhetzner" EXT_IPADDR="192.168.254.2" diff --git a/roles/elevate/media/templates/firewall/elevate-office.sh.j2 b/roles/elevate/media/templates/firewall/elevate-office.sh.j2 index b2f7f416..93805cdf 100644 --- a/roles/elevate/media/templates/firewall/elevate-office.sh.j2 +++ b/roles/elevate/media/templates/firewall/elevate-office.sh.j2 @@ -15,7 +15,7 @@ MANGLE="$IPTABLES -t mangle" FILTER6="$IP6TABLES -t filter" MANGLE6="$IP6TABLES -t mangle" -LAN_IF="{{ network.primary.interface }}" +LAN_IF="{{ network.primary.name }}" LAN_IPADDR="192.168.0.250" LAN_NETMASK="255.255.255.0" diff --git a/roles/elevate/media/templates/firewall/lan-only.sh.j2 b/roles/elevate/media/templates/firewall/lan-only.sh.j2 index 4431ade0..85f0cde4 100644 --- a/roles/elevate/media/templates/firewall/lan-only.sh.j2 +++ b/roles/elevate/media/templates/firewall/lan-only.sh.j2 @@ -15,9 +15,9 @@ MANGLE="$IPTABLES -t mangle" FILTER6="$IP6TABLES -t filter" MANGLE6="$IP6TABLES -t mangle" -LAN_IF="{{ network.primary.interface }}" -LAN_IPADDR="{{ network.primary.ip }}" -LAN_NETMASK="{{ network.primary.mask }}" +LAN_IF="{{ network.primary.name }}" +LAN_IPADDR="{{ network.primary.address | ipaddr('address') }}" +LAN_NETMASK="{{ network.primary.address | ipaddr('netmask') }}" ######################### diff --git a/roles/elevate/media/templates/firewall/r3-with-lan.sh.j2 b/roles/elevate/media/templates/firewall/r3-with-lan.sh.j2 index c65e42ed..fb2d45a9 100644 --- a/roles/elevate/media/templates/firewall/r3-with-lan.sh.j2 +++ b/roles/elevate/media/templates/firewall/r3-with-lan.sh.j2 @@ -15,11 +15,11 @@ MANGLE="$IPTABLES -t mangle" FILTER6="$IP6TABLES -t filter" MANGLE6="$IP6TABLES -t mangle" -LAN_IF="{{ network.primary.interface }}" -LAN_IPADDR="{{ network.primary.ip }}" -LAN_NETMASK="{{ network.primary.mask }}" +LAN_IF="{{ network.primary.name }}" +LAN_IPADDR="{{ network.primary.address | ipaddr('address') }}" +LAN_NETMASK="{{ network.primary.address | ipaddr('netmask') }}" -EXT_IF="{{ network.primary.interface }}.{{ network_zones.ccinet.vlan }}" +EXT_IF="{{ network.primary.name }}.{{ network_zones.ccinet.vlan }}" EXT_IPADDR="89.106.211.61" EXT_SERVICES_TCP="80 443 {{ ansible_port }}" diff --git a/roles/elevate/media/templates/firewall/r3.sh.j2 b/roles/elevate/media/templates/firewall/r3.sh.j2 index 83a6297f..a8425825 100644 --- a/roles/elevate/media/templates/firewall/r3.sh.j2 +++ b/roles/elevate/media/templates/firewall/r3.sh.j2 @@ -15,7 +15,7 @@ MANGLE="$IPTABLES -t mangle" FILTER6="$IP6TABLES -t filter" MANGLE6="$IP6TABLES -t mangle" -EXT_IF="{{ network.primary.interface }}" +EXT_IF="{{ network.primary.name }}" EXT_IPADDR="89.106.211.61" EXT_SERVICES_TCP="80 443 {{ ansible_port }}" diff --git a/roles/elevate/media/templates/netplan/elevate-festival.yaml.j2 b/roles/elevate/media/templates/netplan/elevate-festival.yaml.j2 index 3bd97cb6..9ca54c55 100644 --- a/roles/elevate/media/templates/netplan/elevate-festival.yaml.j2 +++ b/roles/elevate/media/templates/netplan/elevate-festival.yaml.j2 @@ -2,8 +2,8 @@ network: version: 2 renderer: networkd ethernets: - {{ network.primary.interface }}: - addresses: [ {{ (network.primary.ip + '/' + network.primary.mask) | ipaddr('address/prefix') }} ] + {{ network.primary.name }}: + addresses: [ {{ network.primary.address }} ] gateway4: {{ network.primary.gateway }} accept-ra: false nameservers: diff --git a/roles/elevate/media/templates/netplan/elevate-office.yaml.j2 b/roles/elevate/media/templates/netplan/elevate-office.yaml.j2 index acc944fd..1dcecf7a 100644 --- a/roles/elevate/media/templates/netplan/elevate-office.yaml.j2 +++ b/roles/elevate/media/templates/netplan/elevate-office.yaml.j2 @@ -2,7 +2,7 @@ network: version: 2 renderer: networkd ethernets: - {{ network.primary.interface }}: + {{ network.primary.name }}: addresses: [ 192.168.0.250/24 ] gateway4: 192.168.0.1 accept-ra: false diff --git a/roles/elevate/media/templates/netplan/lan-only.yaml.j2 b/roles/elevate/media/templates/netplan/lan-only.yaml.j2 index 3bd97cb6..9ca54c55 100644 --- a/roles/elevate/media/templates/netplan/lan-only.yaml.j2 +++ b/roles/elevate/media/templates/netplan/lan-only.yaml.j2 @@ -2,8 +2,8 @@ network: version: 2 renderer: networkd ethernets: - {{ network.primary.interface }}: - addresses: [ {{ (network.primary.ip + '/' + network.primary.mask) | ipaddr('address/prefix') }} ] + {{ network.primary.name }}: + addresses: [ {{ network.primary.address }} ] gateway4: {{ network.primary.gateway }} accept-ra: false nameservers: diff --git a/roles/elevate/media/templates/netplan/r3-with-lan.yaml.j2 b/roles/elevate/media/templates/netplan/r3-with-lan.yaml.j2 index 275ef953..3dbfeba6 100644 --- a/roles/elevate/media/templates/netplan/r3-with-lan.yaml.j2 +++ b/roles/elevate/media/templates/netplan/r3-with-lan.yaml.j2 @@ -2,13 +2,13 @@ network: version: 2 renderer: networkd ethernets: - {{ network.primary.interface }}: - addresses: [ {{ (network.primary.ip + '/' + network.primary.mask) | ipaddr('address/prefix') }} ] + {{ network.primary.name }}: + addresses: [ {{ network.primary.address }} ] accept-ra: false vlans: - {{ network.primary.interface }}.{{ network_zones.ccinet.vlan }}: + {{ network.primary.name }}.{{ network_zones.ccinet.vlan }}: id: {{ network_zones.ccinet.vlan }} - link: {{ network.primary.interface }} + link: {{ network.primary.name }} addresses: [ 89.106.211.61/27 ] gateway4: 89.106.211.33 accept-ra: false diff --git a/roles/elevate/media/templates/netplan/r3.yaml.j2 b/roles/elevate/media/templates/netplan/r3.yaml.j2 index 2429a4b7..91654c09 100644 --- a/roles/elevate/media/templates/netplan/r3.yaml.j2 +++ b/roles/elevate/media/templates/netplan/r3.yaml.j2 @@ -2,7 +2,7 @@ network: version: 2 renderer: networkd ethernets: - {{ network.primary.interface }}: + {{ network.primary.name }}: addresses: [ 89.106.211.61/27 ] gateway4: 89.106.211.33 accept-ra: false |