mirror of https://github.com/Icinga/icinga2.git
Config: add macros/custom dictionaries to Host Service definition
additive inheritance (+=) works with templates too.
This commit is contained in:
parent
2cc8ef17e1
commit
d5579d9e2f
|
@ -231,6 +231,8 @@ void Host::UpdateSlaveServices(void)
|
||||||
keys.insert("servicedependencies");
|
keys.insert("servicedependencies");
|
||||||
keys.insert("hostdependencies");
|
keys.insert("hostdependencies");
|
||||||
keys.insert("export_macros");
|
keys.insert("export_macros");
|
||||||
|
keys.insert("macros");
|
||||||
|
keys.insert("custom");
|
||||||
|
|
||||||
ExpressionList::Ptr host_exprl = boost::make_shared<ExpressionList>();
|
ExpressionList::Ptr host_exprl = boost::make_shared<ExpressionList>();
|
||||||
item->GetLinkedExpressionList()->ExtractFiltered(keys, host_exprl);
|
item->GetLinkedExpressionList()->ExtractFiltered(keys, host_exprl);
|
||||||
|
|
|
@ -50,6 +50,10 @@ type Host {
|
||||||
%attribute string "*"
|
%attribute string "*"
|
||||||
},
|
},
|
||||||
|
|
||||||
|
%attribute dictionary "custom" {
|
||||||
|
%attribute string "*"
|
||||||
|
},
|
||||||
|
|
||||||
%attribute name(CheckCommand) "check_command",
|
%attribute name(CheckCommand) "check_command",
|
||||||
|
|
||||||
%attribute name(TimePeriod) "check_period",
|
%attribute name(TimePeriod) "check_period",
|
||||||
|
@ -156,6 +160,10 @@ type Host {
|
||||||
%attribute string "*"
|
%attribute string "*"
|
||||||
},
|
},
|
||||||
|
|
||||||
|
%attribute dictionary "custom" {
|
||||||
|
%attribute string "*"
|
||||||
|
},
|
||||||
|
|
||||||
%attribute array "servicegroups" {
|
%attribute array "servicegroups" {
|
||||||
%attribute name(ServiceGroup) "*"
|
%attribute name(ServiceGroup) "*"
|
||||||
},
|
},
|
||||||
|
@ -193,6 +201,10 @@ type Service {
|
||||||
%attribute string "*"
|
%attribute string "*"
|
||||||
},
|
},
|
||||||
|
|
||||||
|
%attribute dictionary "custom" {
|
||||||
|
%attribute string "*"
|
||||||
|
},
|
||||||
|
|
||||||
%require "check_command",
|
%require "check_command",
|
||||||
%attribute name(CheckCommand) "check_command",
|
%attribute name(CheckCommand) "check_command",
|
||||||
%attribute number "max_check_attempts",
|
%attribute number "max_check_attempts",
|
||||||
|
|
Loading…
Reference in New Issue