MCPcopy Create free account
hub / github.com/Icinga/icinga2 / WriteStageConfig

Method WriteStageConfig

lib/remote/configpackageutility.cpp:148–157  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

146}
147
148void ConfigPackageUtility::WriteStageConfig(const String& packageName, const String& stageName)
149{
150 AtomicFile fp(GetPackageDir() + "/" + packageName + "/" + stageName + "/include.conf", 0644);
151 fp << "include \"../active.conf\"\n"
152 << "if (ActiveStages[\"" << packageName << "\"] == \"" << stageName << "\") {\n"
153 << " include_recursive \"conf.d\"\n"
154 << " include_zones \"" << packageName << "\", \"zones.d\"\n"
155 << "}\n";
156 fp.Commit();
157}
158
159void ConfigPackageUtility::ActivateStage(const String& packageName, const String& stageName)
160{

Callers

nothing calls this directly

Calls 1

CommitMethod · 0.45

Tested by

no test coverage detected