diff --git a/juniper-macros.j2 b/juniper-macros.j2 index 39ab1d1..588beac 100644 --- a/juniper-macros.j2 +++ b/juniper-macros.j2 @@ -213,7 +213,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='-')|natsort %} +{% for interface in device.interfaces.filter(name__contains='-')|natsort(key="name") %} {{ interfaceconfig(interface) }} {% endfor %} {% for interface in device.interfaces.filter(name__startswith='ae') %}