mirror of https://github.com/Icinga/icinga2.git
Ensure directory paths are created from stage -> prod
This commit is contained in:
parent
c2d7063ae7
commit
2ed56b50a4
|
@ -369,7 +369,12 @@ void ApiListener::TryActivateZonesStageCallback(const ProcessResult& pr,
|
|||
Log(LogCritical, "ApiListener")
|
||||
<< "Copying file '" << path << "' from config sync staging to production directory.";
|
||||
|
||||
Utility::CopyFile(GetApiZonesStageDir() + path, GetApiZonesDir() + path);
|
||||
String stagePath = GetApiZonesStageDir() + path;
|
||||
String currentPath = GetApiZonesDir() + path;
|
||||
|
||||
Utility::MkDirP(Utility::DirName(currentPath), 0755);
|
||||
|
||||
Utility::CopyFile(stagePath, currentPath);
|
||||
}
|
||||
|
||||
if (reload)
|
||||
|
|
Loading…
Reference in New Issue