Fix(?) whitespace
parent
2a22e2d507
commit
d589158826
|
|
@ -113,7 +113,7 @@ chassis {
|
|||
|
||||
|
||||
{% macro interfaceconfig(interface,rack = None) -%}
|
||||
{%- if not ('-' in interface.name) or interface.description or interface.lag or interface.ip_addresses.count() or interface.connected_endpoints or interface.mode or interface.tagged_vlans.all() or interface.untagged_vlan %}
|
||||
{% if not ('-' in interface.name) or interface.description or interface.lag or interface.ip_addresses.count() or interface.connected_endpoints or interface.mode or interface.tagged_vlans.all() or interface.untagged_vlan %}
|
||||
{{ interface.name }} {
|
||||
{% if interface.description %}
|
||||
description "{{ interface.description }}";
|
||||
|
|
@ -196,7 +196,7 @@ chassis {
|
|||
{% endif %}
|
||||
{% endif %}
|
||||
}
|
||||
{%- endif %}
|
||||
{% endif %}
|
||||
{%- endmacro %}
|
||||
|
||||
{% macro interfacesection(device,vlans) %}
|
||||
|
|
@ -216,7 +216,7 @@ interfaces {
|
|||
{% endif %}
|
||||
{# Physical interfaces should be sorted by FPC/PIC/Port value - that's a challenge to do in Jinja so we cheat for now by putting the xe- interfaces first. This won't work for all devices! #}
|
||||
{% for interface in device.interfaces.filter(name__contains='-')|j2_natsort(attribute="name") %}
|
||||
{{ interfaceconfig(interface) }}
|
||||
{{- interfaceconfig(interface) }}
|
||||
{% endfor %}
|
||||
{% for interface in device.interfaces.filter(name__startswith='ae') %}
|
||||
{{ interfaceconfig(interface,device.rack.name[5:]) }}
|
||||
|
|
|
|||
Loading…
Reference in New Issue