mirror of
https://github.com/nttgin/BGPalerter.git
synced 2024-05-19 06:50:08 +00:00
create directory if declared volume doesn't exist
This commit is contained in:
@@ -172,6 +172,10 @@ if (fs.existsSync(vector.configFile)) {
|
||||
|
||||
config.volume = config.volume || global.EXTERNAL_VOLUME_DIRECTORY || "./";
|
||||
|
||||
if (!fs.existsSync(config.volume)){
|
||||
fs.mkdirSync(config.volume);
|
||||
}
|
||||
|
||||
const errorTransport = new FileLogger({
|
||||
logRotatePattern: config.logging.logRotatePattern,
|
||||
filename: 'error-%DATE%.log',
|
||||
@@ -209,7 +213,6 @@ const wlogger = {
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
config.monitors = (config.monitors || []);
|
||||
config.monitors.push({
|
||||
file: "monitorSwUpdates",
|
||||
|
Reference in New Issue
Block a user