We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 022de28 commit 2abecefCopy full SHA for 2abecef
dockers/docker-lldp-sv2/lldpd.conf.j2
@@ -1,3 +1,9 @@
1
{% if MGMT_INTERFACE %}
2
-configure ports eth0 lldp portidsubtype local {{ MGMT_INTERFACE.keys()[0][0] }}
+{# If MGMT port alias is available, use it for port ID subtype, otherwise use port name #}
3
+{% set mgmt_port_name = MGMT_INTERFACE.keys()[0][0] %}
4
+{% if MGMT_PORT and MGMT_PORT[mgmt_port_name] and MGMT_PORT[mgmt_port_name].alias %}
5
+configure ports eth0 lldp portidsubtype local {{ MGMT_PORT[mgmt_port_name].alias }}
6
+{% else %}
7
+configure ports eth0 lldp portidsubtype local {{ mgmt_port_name }}
8
+{% endif %}
9
{% endif %}
0 commit comments