mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-28 16:24:05 +02:00
IcingaHostGroup(Legacy): Render assigned groups to all zones
So we still can support hosts with direct groups. refs #13049
This commit is contained in:
parent
aaeca533fc
commit
c2734fd4d4
@ -59,6 +59,15 @@ class IcingaHostGroup extends IcingaObjectGroup
|
|||||||
} else {
|
} else {
|
||||||
$allMembers = array();
|
$allMembers = array();
|
||||||
|
|
||||||
|
// make sure we write to all zones
|
||||||
|
// so host -> group relations are still possible
|
||||||
|
foreach (IcingaZone::loadAll($conn) as $zone) {
|
||||||
|
$zoneId = $zone->getAutoincId();
|
||||||
|
if (! array_key_exists($zoneId, $zoneMap)) {
|
||||||
|
$zoneMap[$zoneId] = array();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
foreach ($zoneMap as $zoneId => $members) {
|
foreach ($zoneMap as $zoneId => $members) {
|
||||||
$file = $this->legacyZoneHostgroupFile($config, $zoneId);
|
$file = $this->legacyZoneHostgroupFile($config, $zoneId);
|
||||||
$this->properties['members'] = $members;
|
$this->properties['members'] = $members;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user