Girish Ramakrishnan
547a80f17b
make shell.exec options non-optional
2017-09-09 19:54:31 -07:00
Girish Ramakrishnan
e67ecae2d2
typo
2017-09-07 22:01:37 -07:00
Girish Ramakrishnan
75b3e7fc78
resolve symlinks correctly for deletion
...
part of #394
2017-09-07 21:57:08 -07:00
Girish Ramakrishnan
61f7c1af48
Remove unused error codes
2017-08-28 15:27:17 -07:00
Girish Ramakrishnan
78ec8e5c0c
Add field to skip backup for an app
...
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
2017-08-16 16:36:50 -07:00
Girish Ramakrishnan
4f1a596123
Add support for exoscale SOS
2017-07-25 15:23:04 -07:00
Girish Ramakrishnan
414e9bdf05
Do not use lastBackupId in cleanup logic
...
lastBackupId is only used as a "message" passing field for apptask restore.
Theoretically, this code somehow protects a race between the cleanup logic
and the restore apptask. this is unlikely to happen and adds unnecessary
complexity.
2017-06-01 14:47:57 -07:00
Girish Ramakrishnan
c342e52e7d
Record copyLastBackup in the backupdb
2017-06-01 14:08:55 -07:00
Girish Ramakrishnan
78aa9c66f7
Add a note why we do not cleanup more aggressively yet
2017-06-01 10:33:49 -07:00
Girish Ramakrishnan
986ec02ac6
Add debug on what backup is preserved
2017-06-01 09:38:39 -07:00
Girish Ramakrishnan
f34d429052
kill the backup process if it runs for too long
2017-05-30 16:11:12 -07:00
Girish Ramakrishnan
b04a417cfc
Cleanup errored and creating backups
...
Fixes #330
2017-05-30 15:16:08 -07:00
Girish Ramakrishnan
77641f4b51
Add backupdb.getByState and backupdb.getByTypeAndState
...
part of #330
2017-05-30 14:30:06 -07:00
Girish Ramakrishnan
765d20c8be
Add backup states to track unfinished backups
...
part of #330
2017-05-30 13:43:30 -07:00
Girish Ramakrishnan
d2420de594
refactor backup cleanup logic
2017-05-30 13:43:30 -07:00
Girish Ramakrishnan
6fc69c05ca
Add noop storage backend
...
This is sometimes useful when an update gets stuck because of some
bug in backup logic.
Note that you cannot restore from this backend because nothing is
saved.
2017-05-22 10:45:01 -07:00
Johannes Zellner
3fad5e856c
Do not cleanup any app backups which are referenced by an app through lastBackupId
2017-04-24 13:50:46 +02:00
Johannes Zellner
cc66830a2d
Also cleanup app backups which are not referenced by a box backup
2017-04-24 13:41:23 +02:00
Johannes Zellner
880f7b4cd3
Allow to get backups by type in backupdb
2017-04-24 12:41:19 +02:00
Johannes Zellner
410420e9d5
Ensure we keep at least one backup on cleanup
...
If for some reason backups fail for longer than the retention time
we should at least keep the latest around
2017-04-24 12:01:52 +02:00
Girish Ramakrishnan
aeba8e8fd2
Use retentionSecs to cleanup backups
...
Part of #310
2017-04-23 19:34:00 -07:00
Girish Ramakrishnan
a0e122e578
Try to make tests work again
2017-04-23 18:03:40 -07:00
Girish Ramakrishnan
d91e8bb87b
add minio as a separate backend
...
Fixes #308
2017-04-22 13:34:43 -07:00
Johannes Zellner
a7d7935451
Remove backup download code
2017-04-22 22:17:29 +02:00
Girish Ramakrishnan
6c8b9b8799
Propagate error messages from backuptask into box code
2017-04-21 14:26:34 -07:00
Johannes Zellner
33492333c7
Fix backupDone() for caas
2017-04-21 10:31:43 +02:00
Girish Ramakrishnan
64c2f3d8c3
copyBackup() already returns a BackupError
2017-04-20 18:56:34 -07:00
Girish Ramakrishnan
a5efdb067d
Revert "Add apprestoretask.js"
...
This reverts commit 926224bd5d .
This shouldn't be required. We already fix the perms
See 7035b3c18a
2017-04-20 18:12:29 -07:00
Girish Ramakrishnan
0584ace954
Remove StorageError from backends
2017-04-20 18:12:29 -07:00
Girish Ramakrishnan
2479af23ab
app backups must have app version (and not box version)
2017-04-20 17:29:21 -07:00
Johannes Zellner
926224bd5d
Add apprestoretask.js
2017-04-20 16:10:13 +02:00
Johannes Zellner
6a5b0c194f
No more restore mapping
2017-04-20 15:37:49 +02:00
Johannes Zellner
a94d44da75
Add generic node.sh to run node apps as root and with memory limitations
2017-04-20 15:20:11 +02:00
Johannes Zellner
3cae400b63
We still want to store the restoreConfig config.json as part of the backup itself
2017-04-18 12:16:32 +02:00
Johannes Zellner
23e3b0bd91
Get the restoreConfig from the database instead of the json file
2017-04-18 12:08:26 +02:00
Johannes Zellner
7a39cdda97
Store restoreConfig on backups
2017-04-18 12:02:15 +02:00
Johannes Zellner
a21750a4c9
Fix the mysql dump commandline
2017-04-17 20:26:06 +02:00
Johannes Zellner
7b93150047
Also add intermediate removeAppRestoreConfig() api
2017-04-17 20:26:06 +02:00
Johannes Zellner
ff3a748398
Call backuptask.js directly as root to avoid trampoline shell scripts
2017-04-17 20:26:05 +02:00
Johannes Zellner
e021a4b377
Remove unused restoreapp.sh
2017-04-17 20:26:05 +02:00
Johannes Zellner
3879b55642
Also copy the app restore config file
2017-04-17 20:26:05 +02:00
Johannes Zellner
5e1ad4ad93
We need root access to copy backup files with the filesystem backend
2017-04-17 20:26:05 +02:00
Johannes Zellner
7fdf491815
Add backuptask.js to work with new storage interface
2017-04-17 20:09:02 +02:00
Johannes Zellner
602f8bcd04
Split platform and app data folders and get rid of btrfs volumes
2017-04-04 12:34:55 +02:00
Girish Ramakrishnan
895f5f7398
Expand backup error in the mail
2017-01-26 13:03:36 -08:00
Girish Ramakrishnan
3e21b6cad3
Add ensureBackup log
2017-01-26 12:47:23 -08:00
Johannes Zellner
5219eff190
Remove 'app at' for app backup message
2017-01-12 16:00:57 +01:00
Johannes Zellner
d98f64094e
Set the correct progress percentage
2017-01-12 16:00:56 +01:00
Johannes Zellner
1c9f2495e3
Show the detailed backup progress during update
...
Fixes #157
2017-01-12 16:00:34 +01:00
Girish Ramakrishnan
20a75b7819
tag -> prefix
2017-01-05 23:20:02 -08:00