mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-28 00:04:05 +02:00
IcingaService: cosmetics, render single hosts...
...with equals, multiple ones as "in array" refs #907
This commit is contained in:
parent
409661f7d0
commit
c3fd50003a
@ -411,11 +411,18 @@ class IcingaService extends IcingaObject
|
||||
|
||||
$blacklist = $this->getBlacklistedHostnames();
|
||||
if (! empty($blacklist)) {
|
||||
if (count($blacklist) === 1) {
|
||||
$output .= sprintf(
|
||||
" ignore host.name == %s\n",
|
||||
c::renderString($blacklist[0])
|
||||
);
|
||||
} else {
|
||||
$output .= sprintf(
|
||||
" ignore where host.name in %s\n",
|
||||
c::renderArray($blacklist)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// A hand-crafted command endpoint overrides use_agent
|
||||
if ($this->command_endpoint_id !== null) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user