Don't include in linux-server if parent host

This commit is contained in:
nemunaire 2024-03-12 20:45:04 +01:00
parent b3c2bc0c9e
commit 9505f08a64
1 changed files with 1 additions and 1 deletions

View File

@ -2,7 +2,7 @@ define host {
use linux-server
host_name {{ inventory_hostname_short }}
address {{ inventory_hostname }}
hostgroups linux-servers,{{ ansible_distribution | lower }}-hosts{% if group_names | length > 0 %},{{ group_names | join(",") }}{% endif %}{% if nagios_extra_groups | length > 0 %},{{ nagios_extra_groups | join(",") }}{% endif %}
hostgroups {% if parent_host is not defined %}linux-servers,{% endif %}{{ ansible_distribution | lower }}-hosts{% if group_names | length > 0 %},{{ group_names | join(",") }}{% endif %}{% if nagios_extra_groups | length > 0 %},{{ nagios_extra_groups | join(",") }}{% endif %}
{% if mydomain is defined and mydomain != "ra.nemunai.re" -%}
{% set dn = mydomain.split('.') %}