check if additionalinterfaces is empty
This commit is contained in:
parent
eddd055380
commit
c1961307c9
@ -11,6 +11,7 @@ network:
|
|||||||
{% if netplan.default_gateway is defined and netplan.default_gateway|length > 0 %}
|
{% if netplan.default_gateway is defined and netplan.default_gateway|length > 0 %}
|
||||||
gateway4: {{netplan.default_gateway}}
|
gateway4: {{netplan.default_gateway}}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
{% if netplan.additionalinterfaces is defined and netplan.additionalinterfaces|length > 0 %}
|
||||||
{% for interface in netplan.additionalinterfaces %}
|
{% for interface in netplan.additionalinterfaces %}
|
||||||
{{ interface.name }}:
|
{{ interface.name }}:
|
||||||
dhcp4: {{ interface.dhcp4 }}
|
dhcp4: {{ interface.dhcp4 }}
|
||||||
@ -36,3 +37,4 @@ network:
|
|||||||
search: []
|
search: []
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
{% endif %}
|
||||||
|
Loading…
Reference in New Issue
Block a user