Adding indents.

This commit is contained in:
Jeff Baskin 2016-10-23 19:44:51 -04:00
parent 9de2e18c3e
commit 75f971ae71

View File

@ -11,14 +11,14 @@
default=keepalived_defaults,
merge=True) %}
{%- macro config_entries(data) -%}
{%- macro config_entries(data, indents) -%}
{%- if data is mapping -%}
{%- for entry in data|dictsort -%}
{{ entry[0] }} {
{{ config_entries(entry[1]) }}
{{ entry[0]|indent(indents, True) }} {
{{ config_entries(entry[1], indents + 2) }}
}{{ '\n' }}
{%- endfor -%}
{%- endif -%}
{%- endmacro -%}
{{ config_entries(keepalived_final_values) }}
{{ config_entries(keepalived_final_values, 0) }}