Adding host template to host groups

Hello All,

I have encountered an problem where i need to import host templates with custom config to 50+ hosts, do i have an option to import the template to host groups? Or can anyone suggest an better idea to do this other than importing to every single host manually?

I’m using icinga director now, i remember we will be able to import host template to host groups previously while using config files (If i’m not wrong).

Thanks

I’m not aware of such a possibilty/feature.

What are you trying to achieve with the host template for those 50 hosts. Maybe there is another solution

1 Like

Hi,

I’m working with custom vars for each host (tags like customer, location, host type,…).
You can create a host template which contains i.e. individual customer settings and credentials
and add them to the host via sync rule when you import hosts from a CMDB (i.e. a simple mySQL
table which contains hostname, customer and any other useful info).

This can be done by a sync property with filters. The rule adds a specific customer template to
the host when the filter matches “customer=XXXX”. So each host inherits custom settings and
you have only to change them on one place within the template.

Greetings,
Manfred

3 Likes