diff --git a/vyos.conf.j2 b/vyos.conf.j2 index 23050ec..99acfb3 100644 --- a/vyos.conf.j2 +++ b/vyos.conf.j2 @@ -121,6 +121,17 @@ protocols { abr-type {{ salt['pillar.get']('protocols:ospf:parameters:abr-type','cisco') }} } + {% if 'default-information' in salt['pillar.get']('protocols:ospf') %} + default-information { + {% if 'originate' in salt['pillar.get']('protocols:ospf:default-information') %} + originate { + {% if salt['pillar.get']('protocols:ospf:default-information:originate:metric',None) %}metric {{ salt['pillar.get']('protocols:ospf:default-information:originate:metric') }}{% endif %} + {% if salt['pillar.get']('protocols:ospf:default-information:originate:metric-type',None) %}metric-type {{ salt['pillar.get']('protocols:ospf:default-information:originate:metric-type') }}{% endif %} + } + {% endif %} + } + {% endif %} + {% for iface_name, iface_data in pillar['netbox']['interfaces'].items() %}{% if salt['pillar.get']('interfaces:'+iface_name+':ip:ospf:passive') %} passive-interface {{ iface_name }} {% endif %}{% endfor %}