ansible/roles/icinga/templates/icinga2/conf.d/hosts.conf.j2

13 lines
363 B
Django/Jinja

{% for host in groups['all'] %}
object Host "{{ host }}" {
/* Import the default host template defined in `templates.conf`. */
import "generic-host"
/* Specify the address attributes for checks e.g. `ssh` or `http`. */
address = "{{ host }}"
/* Set custom variable `os` for hostgroup assignment in `groups.conf`. */
vars.os = "Linux"
}
{% endfor %}