Skip to content

Commit

Permalink
Code refactoring
Browse files Browse the repository at this point in the history
Signed-off-by: Petro Bratash <petrox.bratash@intel.com>
  • Loading branch information
bratashX committed Nov 5, 2020
1 parent ad58479 commit 0e81cc3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions dockers/docker-lldp/lldpd.conf.j2
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{% set mgmt_if = {} %}
{% if MGMT_INTERFACE %}
{% for interface in MGMT_INTERFACE.keys()|list %}
{% if interface[1]|ipv4 %}
{% if mgmt_if.update({'port_name' : interface[0]}) %} {% endif %}
{% if mgmt_if.update({'ipv4' : interface[1].split('/')[0]}) %} {% endif %}
{% for (mgmt_name, mgmt_prefix) in MGMT_INTERFACE|pfx_filter %}
{% if mgmt_prefix|ipv4 %}
{% if mgmt_if.update({'port_name' : mgmt_name}) %} {% endif %}
{% if mgmt_if.update({'ipv4' : mgmt_prefix|ip}) %} {% endif %}
{% endif %}
{% endfor %}
{% endif %}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configure ports eth0 lldp portidsubtype local eth0
configure system ip management pattern 10.0.0.100
configure system hostname switch-t0
pause
pause
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configure system hostname switch-t0
pause
pause

0 comments on commit 0e81cc3

Please sign in to comment.