IcingaConfig: do not render v2-related helpers...

...for legacy config
This commit is contained in:
Thomas Gelf 2016-09-05 19:34:14 +00:00
parent 687f2aff1c
commit e58a70613c
1 changed files with 8 additions and 2 deletions

View File

@ -431,8 +431,10 @@ class IcingaConfig
->createFileFromDb('notification')
;
$this->configFile('zones.d/director-global/commands')
->prepend("library \"methods\"\n\n");
if (! $this->isLegacy()) {
$this->configFile('zones.d/director-global/commands')
->prepend("library \"methods\"\n\n");
}
PrefetchCache::forget();
IcingaHost::clearAllPrefetchCaches();
@ -444,6 +446,10 @@ class IcingaConfig
protected function prepareGlobalBasics()
{
if ($this->isLegacy()) {
return $this;
}
$this->configFile(
sprintf(
'zones.d/%s/001-director-basics',