This skips the app from a backup when doing a full box backup and simply reuses the previous backup. The app can still be explicitly backed up using 'cloudron backup' and explicitly restored using 'cloudron restore --backup'. When restoring the box, it all depends on the app's last backup. Fixes #311
17 lines
422 B
JavaScript
17 lines
422 B
JavaScript
'use strict';
|
|
|
|
exports.up = function(db, callback) {
|
|
db.runSql('ALTER TABLE apps ADD COLUMN enableBackup BOOLEAN DEFAULT 1', function (error) {
|
|
if (error) console.error(error);
|
|
callback(error);
|
|
});
|
|
};
|
|
|
|
exports.down = function(db, callback) {
|
|
db.runSql('ALTER TABLE apps DROP COLUMN enableBackup', function (error) {
|
|
if (error) console.error(error);
|
|
callback(error);
|
|
});
|
|
};
|
|
|