@@ -77,7 +77,7 @@ zone "{{ key }}" {
7777include "{{ map.default_zones_config }}";
7878{% - endif %}
7979
80- {% for key , args in salt ['pillar.get' ]('bind:configured_zones' , {}). items () -%}
80+ {% for key , args in salt ['pillar.get' ]('bind:configured_zones' , {})|dictsort -%}
8181{% - if salt ['pillar.get' ]("bind:configured_zones:" + key + ":file" ) -%}
8282{% - set file = salt ['pillar.get' ]("bind:configured_zones:" + key + ":file" ) %}
8383{% else %}
@@ -92,7 +92,7 @@ include "{{ map.default_zones_config }}";
9292{{ zone(key, args, file, masters) }}
9393{% endfor %}
9494
95- {% for view , view_data in salt ['pillar.get' ]('bind:configured_views' , {}). items () %}
95+ {% for view , view_data in salt ['pillar.get' ]('bind:configured_views' , {})|dictsort %}
9696
9797view {{ view }} {
9898{% - if view == 'default' %}
@@ -105,7 +105,7 @@ match-clients {
105105{% - endfor %}
106106};
107107
108- {% for key , args in view_data .get ('configured_zones' , {}). items () -%}
108+ {% for key , args in view_data .get ('configured_zones' , {})|dictsort -%}
109109{% - set file = salt ['pillar.get' ]("bind:available_zones:" + key + ":file" ) %}
110110{% - set masters = salt ['pillar.get' ]("bind:available_zones:" + key + ":masters" ) %}
111111 {{ zone(key, args, file, masters) }}
@@ -129,7 +129,7 @@ logging {
129129
130130{% - if salt ['pillar.get' ]('bind:controls' , False ) %}
131131controls {
132- {% - for name , control in salt ['pillar.get' ]('bind:controls' ). iteritems () if control .get ('enabled' , True ) %}
132+ {% - for name , control in salt ['pillar.get' ]('bind:controls' )|dictsort if control .get ('enabled' , True ) %}
133133 inet {{ control.get('bind', {}).get('address', '127.0.0.1') }} port {{ control.get('bind', {}).get('port', 953) }}
134134 {% - if control .get ('allow' ) %}
135135 allow {
@@ -151,7 +151,7 @@ controls {
151151
152152{% - if salt ['pillar.get' ]('bind:statistics' , False ) %}
153153statistics-channels {
154- {% - for name , channel in salt ['pillar.get' ]('bind:statistics' ). iteritems () if channel .get ('enabled' , True ) %}
154+ {% - for name , channel in salt ['pillar.get' ]('bind:statistics' )|dictsort if channel .get ('enabled' , True ) %}
155155 inet {{ channel.get('bind', {}).get('address', '127.0.0.1') }} port {{ channel.get('bind', {}).get('port', 953) }}
156156 {% - if channel .get ('allow' ) %}
157157 allow {
@@ -165,15 +165,15 @@ statistics-channels {
165165{% - endif %}
166166
167167
168- {% - for name , data in salt ['pillar.get' ]('bind:configured_acls' , {}). items () %}
168+ {% - for name , data in salt ['pillar.get' ]('bind:configured_acls' , {})|dictsort %}
169169acl {{ name }} {
170170 {% - for d in data %}
171171 {{ d }};
172172 {% - endfor %}
173173};
174174{% - endfor %}
175175
176- {% - for name , data in salt ['pillar.get' ]('bind:configured_masters' , {}). items () %}
176+ {% - for name , data in salt ['pillar.get' ]('bind:configured_masters' , {})|dictsort %}
177177masters {{ name }} {
178178 {% - for d in data %}
179179 {{ d }};
0 commit comments