Skip to content

Commit

Permalink
fix: sort extra options in configuration
Browse files Browse the repository at this point in the history
Ensure extra options in generated configuration is sorted, to ensure stable
configuration.
  • Loading branch information
Adrien "ze" Urban committed Oct 28, 2021
1 parent 99b1469 commit 89cdcec
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion salt/files/master.d/f_defaults.conf
Original file line number Diff line number Diff line change
Expand Up @@ -1821,7 +1821,7 @@ alternative.mongo.{{ name }}: {{ value }}
{% endif %}
{%- endif %}

{%- for configname in cfg_master %}
{%- for configname in cfg_master|sort %}
{%- if configname not in reserved_keys and configname not in default_keys %}
{{ configname }}:
{{ cfg_master[configname]| yaml(False) | indent(2) }}
Expand Down
2 changes: 1 addition & 1 deletion salt/files/minion.d/f_defaults.conf
Original file line number Diff line number Diff line change
Expand Up @@ -1251,7 +1251,7 @@ alternative.mongo.{{ name }}: {{ value }}
{% endif %}
{%- endif %}

{%- for configname in cfg_minion %}
{%- for configname in cfg_minion|sort %}
{%- if configname not in reserved_keys and configname not in default_keys %}
{%- if cfg_minion[configname] is iterable and cfg_minion[configname] is not mapping and cfg_minion[configname] is not string %}
{{ configname }}:
Expand Down

0 comments on commit 89cdcec

Please sign in to comment.