ansible-role-grafana/templates/grafana.ini.j2

16 lines
428 B
Text
Raw Normal View History

2019-04-11 17:20:56 +00:00
# {{ ansible_managed }}
2020-02-12 20:49:40 +00:00
{% for section, options in grafana_config.items() %}
2019-04-11 17:20:56 +00:00
{% if section|lower != 'default' %}
[{{ section }}]
{% endif %}
2020-02-12 20:49:40 +00:00
{% for option, value in options.items() %}
2019-04-11 17:20:56 +00:00
{{ option }} = {% if value is sameas true %}true
{% elif value is sameas false %}false
{% elif value is string %}"{{ value }}"
{% elif value is number %}{{ value }}
{% else %}["{{ value|join('", "') }}"]
{% endif %}
{% endfor %}
{% endfor %}