backups: print the app index/total

This commit is contained in:
Girish Ramakrishnan
2021-11-02 18:07:19 -07:00
parent de2c596394
commit ce4f5c0ad6
+4 -3
View File
@@ -1037,12 +1037,13 @@ async function fullBackup(options, progressCallback) {
let step = 100/(allApps.length+3);
const appBackupIds = [];
for (const app of allApps) {
progressCallback({ percent: percent, message: `Backing up ${app.fqdn}` });
for (let i = 0; i < allApps.length; i++) {
const app = allApps[i];
progressCallback({ percent: percent, message: `Backing up ${app.fqdn} (${i+1}/${allApps.length})` });
percent += step;
if (!app.enableBackup) {
debug(`fullBackup: skipped backup ${app.fqdn}`);
debug(`fullBackup: skipped backup ${app.fqdn} (${i+1}/${allApps.length})`);
continue; // nothing to backup
}