use dicts instead of lists to make merging work more nicely

master
Marek Isalski 6 years ago
parent ad775bffe9
commit 1056ddfdb9

@ -115,7 +115,7 @@ protocols {
{% endif %}{% endfor %}
{% for area_name, area_data in pillar['protocols']['ospf']['area'].items() %}
area {{ area_name }} {
{% for network in area_data['networks'] %}
{% for network, network_data in area_data['networks'].items() %}
network {{ network }}
{% endfor %}
}
@ -129,11 +129,11 @@ protocols {
{% for area_name, area_data in pillar['protocols']['ospfv3']['area'].items() %}
area {{ area_name }} {
{% for range in area_data.get('range',[]) %}
{% for range, range_data in area_data.get('range',{}).items() %}
range {{ range }} {
}
{% endfor %}
{% for interface in area_data.get('interface',[]) %}
{% for interface, interface_data in area_data.get('interface',{}).items() %}
interface {{ interface }}
{% endfor %}
}

Loading…
Cancel
Save