jinja whitespace
This commit is contained in:
parent
df3587032d
commit
5f1e304301
@ -21,6 +21,16 @@ systemd_networkd_configs:
|
|||||||
src: vlan.netdev.j2
|
src: vlan.netdev.j2
|
||||||
- name: vlan110.network
|
- name: vlan110.network
|
||||||
src: vlan.network.j2
|
src: vlan.network.j2
|
||||||
|
address:
|
||||||
|
ipv4: 10.192.110.1/24
|
||||||
|
ipv6:
|
||||||
|
gateway:
|
||||||
|
ipv4: 10.192.110.254
|
||||||
|
ipv6:
|
||||||
|
nameserver:
|
||||||
|
ipv4:
|
||||||
|
10.192.110.254
|
||||||
|
ipv6:
|
||||||
|
|
||||||
qemu_bridges:
|
qemu_bridges:
|
||||||
br0
|
br0
|
||||||
|
@ -5,26 +5,27 @@ Name={{ item.name | regex_replace('^[0-9]*-', '') | regex_replace('\.netdev', '
|
|||||||
ARP={{ item.arp }}
|
ARP={{ item.arp }}
|
||||||
|
|
||||||
[Network]
|
[Network]
|
||||||
{% if item.nameserver.ipv4 is defined %}
|
{% if item.nameserver.ipv4 is defined -%}
|
||||||
{% for nameserver in item.nameserver.ipv4 %}
|
{% for nameserver in item.nameserver.ipv4 -%}
|
||||||
DNS={{ nameserver }}
|
DNS={{ nameserver }}
|
||||||
{% endfor %}
|
{% endfor -%}
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
{% if item.nameserver.ipv6 is defined %}
|
{% if item.nameserver.ipv6 is defined -%}
|
||||||
{% for nameserver in item.nameserver.ipv6 %}
|
{% for nameserver in item.nameserver.ipv6 -%}
|
||||||
DNS={{ nameserver }}
|
DNS={{ nameserver }}
|
||||||
{% endfor %}
|
{% endfor -%}
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
|
|
||||||
{% if item.address.ipv4 is defined %}
|
{% if item.address.ipv4 is defined %}
|
||||||
[Address]
|
[Address]
|
||||||
Address={{ item.address.ipv4 }}
|
Address={{ item.address.ipv4 }}
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
|
|
||||||
{% if item.address.ipv6 is defined %}
|
{% if item.address.ipv6 is defined %}
|
||||||
[Address]
|
[Address]
|
||||||
Address={{ item.address.ipv6 }}
|
Address={{ item.address.ipv6 }}
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
|
|
||||||
|
|
||||||
{% if item.gateway.ipv4 is defined %}
|
{% if item.gateway.ipv4 is defined %}
|
||||||
[Route]
|
[Route]
|
||||||
@ -33,12 +34,12 @@ Gateway={{ item.gateway.ipv4 }}
|
|||||||
Scope=global
|
Scope=global
|
||||||
Protocol=static
|
Protocol=static
|
||||||
Type=unicast
|
Type=unicast
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
|
|
||||||
{% if item.gateway.ipv6 is defined %}
|
{% if item.gateway.ipv6 is defined %}
|
||||||
[Route]
|
[Route]
|
||||||
Destination=::/0
|
Destination=::/0
|
||||||
Gateway={{ item.gateway.ipv4 }}
|
Gateway={{ item.gateway.ipv6 }}
|
||||||
Protocol=static
|
Protocol=static
|
||||||
Type=unicast
|
Type=unicast
|
||||||
{% endif %}
|
{% endif -%}
|
Loading…
Reference in New Issue
Block a user