mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-11-13 07:11:34 -05:00
DB record expire in config + Mesh folder optimizations
This commit is contained in:
6
db.js
6
db.js
@@ -35,6 +35,12 @@ module.exports.CreateDB = function (parent) {
|
||||
obj.identifier = null;
|
||||
obj.dbKey = null;
|
||||
|
||||
// Read expiration time from configuration file
|
||||
if (typeof obj.parent.args.dbexpire == 'object') {
|
||||
if (typeof obj.parent.args.dbexpire.events == 'number') { expireEventsSeconds = obj.parent.args.dbexpire.events; }
|
||||
if (typeof obj.parent.args.dbexpire.powerevents == 'number') { expirePowerEventsSeconds = obj.parent.args.dbexpire.powerevents; }
|
||||
}
|
||||
|
||||
if (obj.parent.args.mongodb) {
|
||||
// Use MongoDB
|
||||
obj.databaseType = 2;
|
||||
|
||||
Reference in New Issue
Block a user