Disabled automatic sorting of mapping keys in jinja templatingtags/v0.55.0
- template: jinja | - template: jinja | ||||
{% if 'source_path' not in nginx.server.config %} | {% if 'source_path' not in nginx.server.config %} | ||||
- context: | - context: | ||||
config: {{ nginx.server.config|json() }} | |||||
config: {{ nginx.server.config|json(sort_keys=False) }} | |||||
{% endif %} | {% endif %} |
{% macro sls_block(dict) %} | {% macro sls_block(dict) %} | ||||
{% for key, value in dict.items() %} | {% for key, value in dict.items() %} | ||||
- {{ key }}: {{ value|json() }} | |||||
- {{ key }}: {{ value|json(sort_keys=False) }} | |||||
{% endfor %} | {% endfor %} | ||||
{% endmacro %} | {% endmacro %} | ||||
- service: nginx_service | - service: nginx_service | ||||
{% if 'source_path' not in settings.config %} | {% if 'source_path' not in settings.config %} | ||||
- context: | - context: | ||||
config: {{ settings.config|json() }} | |||||
config: {{ settings.config|json(sort_keys=False) }} | |||||
{% endif %} | {% endif %} | ||||
{% if 'overwrite' in settings and settings.overwrite == False %} | {% if 'overwrite' in settings and settings.overwrite == False %} | ||||
- unless: | - unless: |