1
0
Fork 0
mirror of https://github.com/Ylianst/MeshCentral.git synced 2025-03-09 15:40:18 +00:00

Added backupconfig command in server console.

This commit is contained in:
Ylian Saint-Hilaire 2019-06-07 16:44:00 -07:00
parent 365e7af6fd
commit 997326b44f
5 changed files with 54 additions and 6 deletions

View file

@ -546,7 +546,7 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use
case 'help': {
r = 'Available commands: help, info, versions, args, resetserver, showconfig, usersessions, tasklimiter, setmaxtasks, cores,\r\n'
r += 'migrationagents, agentstats, webstats, mpsstats, swarmstats, acceleratorsstats, updatecheck, serverupdate, nodeconfig,\r\n';
r += 'heapdump, relays, autobackup, dupagents.';
r += 'heapdump, relays, autobackup, backupconfig, dupagents.';
break;
}
case 'dupagents': {
@ -737,6 +737,10 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use
if (backupResult == 0) { r = 'Starting auto-backup...'; } else { r = 'Backup alreay in progress.'; }
break;
}
case 'backupconfig': {
r = parent.db.getBackupConfig();
break;
}
default: { // This is an unknown command, return an error message
r = 'Unknown command \"' + cmd + '\", type \"help\" for list of avaialble commands.';
break;