Skip to content
Snippets Groups Projects
Commit cfcd77fc authored by skorpy's avatar skorpy :construction_worker:
Browse files

lldp: cleanup when there is no lldp interface

parent e494c461
Branches
No related tags found
No related merge requests found
Pipeline #
{%- set lldp = False -%}
{%- for name, interface in pillar.ifaces.items() if 'lldp' in interface -%}
{%- do lldp = True -%}
{%- endfor -%}
{%- if lldp -%}
lldpd:
pkg.installed: []
service.running:
......@@ -14,3 +19,11 @@ lldpd:
- mode: 644
- template: jinja
- source: salt://lldp/files/default-lldp.j2
{%- else %}
purge-lldpd:
pkg.purged: lldpd
purge-lldpd-default:
file.absent:
- filename: /etc/default/lldpd
{% endif %}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment