Context data wrapped with tojson filter.
This commit is contained in:
parent
6a43ccab3a
commit
06859f5fbb
1 changed files with 4 additions and 4 deletions
|
@ -22,11 +22,11 @@ logrotate-{{ key }}:
|
|||
- template: jinja
|
||||
- context:
|
||||
{% if value is mapping %}
|
||||
path: {{ value.get('path', [key]) }}
|
||||
data: {{ value.get('config', []) }}
|
||||
path: {{ value.get('path', [key]) | tojson }}
|
||||
data: {{ value.get('config', []) | tojson }}
|
||||
{% else %}
|
||||
path: [ {{ key }} ]
|
||||
data: {{ value }}
|
||||
path: [ {{ key | tojson }} ]
|
||||
data: {{ value | tojson }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{%- endfor -%}
|
||||
|
|
Loading…
Reference in a new issue