debug out the backup list

This commit is contained in:
Girish Ramakrishnan 2016-10-03 14:31:24 -07:00
parent 4a11b3432b
commit d4fb86f506
1 changed files with 3 additions and 1 deletions

View File

@ -238,6 +238,8 @@ Cloudron.prototype.cloneApp = function (appId, newLocation, portBindings) {
var backups = this.listAppBackups(appId);
console.log('Backups are ', backups);
var data = { location: newLocation, password: this._credentials.password, portBindings: portBindings, backupId: backups[0].id };
var res = request.post(this._origin + '/api/v1/apps/' + appId + '/clone').query({ access_token: this._credentials.accessToken }).send(data).end();
@ -401,7 +403,7 @@ Cloudron.prototype.resetPassword = function (resetToken, password) {
Cloudron.prototype.backupApp = function (appId) {
var res = request.post(this._origin + '/api/v1/apps/' + appId + '/backup').query({ access_token: this._credentials.accessToken }).end();
common.verifyResponse2xx(res, 'Could not schedule backup');
common.verifyResponse2xx(res, 'Could not schedule a backup');
this.waitForApp(appId);
};