Commit Graph

877 Commits

Author SHA1 Message Date
Johannes Zellner
fd0d65b8ce Keep the app source archive with the app instance data dir 2026-01-27 22:01:18 +01:00
Girish Ramakrishnan
a1b4fdf624 csp: allow multiple lines and add presets 2026-01-13 17:39:00 +01:00
Girish Ramakrishnan
c448322367 backups: fix download 2025-12-06 11:19:05 +01:00
Girish Ramakrishnan
620974217a restore: teardown pseudo backup site 2025-12-05 16:12:59 +01:00
Girish Ramakrishnan
cc8db71ecf apps: typo caused invalid backupId 2025-11-26 14:39:16 +01:00
Girish Ramakrishnan
bbdfbe1ab7 restore: when restoring apps, use the latest backup id
this ignores the user provided site information. the site contents may or may
not contain this app.
2025-11-25 18:12:54 +01:00
Johannes Zellner
610651066a Fix tgz app backup download
Fixes #868
2025-11-05 18:14:48 +01:00
Girish Ramakrishnan
5bd6001f95 boxerror: details is not a subobject 2025-10-17 20:42:19 +02:00
Girish Ramakrishnan
54cd9c7afa Use JSON query to remove the app id from site
the original regexp does not work for leading comma like [ "box", "appid" ]
2025-09-30 19:43:08 +02:00
Girish Ramakrishnan
edcffd3417 Remove app from backup sites when uninstalled 2025-09-30 18:22:22 +02:00
Girish Ramakrishnan
5dd5a20fc1 code -> sqlCode 2025-09-29 12:18:26 +02:00
Girish Ramakrishnan
19df2e0baa ER_DUP_ENTRY is passed as code and not in message 2025-09-24 10:50:25 +02:00
Girish Ramakrishnan
5157789774 backups: add per site enabledForUpdates flag
previously, we had a singleton 'main' flag to indicate a site can
be used for updates. with this new approach, we can get rid of the
'primary' concept. each site can be used for updates or not.
2025-09-22 18:03:01 +02:00
Girish Ramakrishnan
c5b7264f1a rename backupTargets to backupSites 2025-09-12 10:32:37 +02:00
Johannes Zellner
12e4441227 BoxError always needs a second argument 2025-08-21 11:20:18 +02:00
Johannes Zellner
5f9789f99f Enforce app count limit during installation 2025-08-20 20:03:09 +02:00
Girish Ramakrishnan
12e073e8cf use node: prefix for requires
mostly because code is being autogenerated by all the AI stuff using
this prefix. it's also used in the stack trace.
2025-08-14 12:55:35 +05:30
Girish Ramakrishnan
1d1197e18a restore: use PENDING_RESTORE instead of PENDING_IMPORT 2025-08-05 12:46:50 +02:00
Girish Ramakrishnan
36ab052dda restore: import with the latest backup on cloudron restore
in previous versions, the single backup target was replaced during
restore. we cannot do this anymore with multiple backup targets.

during cloudron restore, a pseudo target is created and all the apps
are restored using this backup target.
2025-08-04 23:24:06 +02:00
Girish Ramakrishnan
ead6d9c7d3 Fix app import 2025-08-02 20:42:12 +02:00
Girish Ramakrishnan
c935744f4c backups: root ~~canal~~ path surgery
remove rootPath and getBackupFilePath from the backup target and
make this backend specific.
2025-08-02 10:15:34 +02:00
Girish Ramakrishnan
a01e1bad0f backuptarget: pseudo target for import and restore 2025-08-02 00:06:47 +02:00
Girish Ramakrishnan
7192439b2c no need for format specific getBackupFilePath 2025-08-01 20:49:11 +02:00
Girish Ramakrishnan
ea419509f1 backups: add setup/teardown
1. add setup, teardown hooks
2. move the managed mount setup and teardown to filesystem backend
3. remove this vague storage.js

we should convert storageApi into a real object, so we don't have to
keep passing apiConfig around
2025-08-01 15:36:25 +02:00
Girish Ramakrishnan
a1a683ec56 import: use inPlace flag 2025-08-01 13:22:12 +02:00
Girish Ramakrishnan
cbc73f5c9a remove uuid module
built into node.js now
2025-07-28 12:54:09 +02:00
Girish Ramakrishnan
373ef5b7e1 import: make the ui work again 2025-07-28 12:12:43 +02:00
Girish Ramakrishnan
fc4da4408c backups: fix app restore with tgz 2025-07-25 13:39:09 +02:00
Girish Ramakrishnan
59aaabecc7 backups: the get route was accidentally removed 2025-07-25 11:56:31 +02:00
Girish Ramakrishnan
62017b3ff5 backup: rename back backuplisting.js to backups.js
this was a transitional rename till I figured out how to split
it in backuptargets.js
2025-07-25 01:37:19 +02:00
Girish Ramakrishnan
3aafbd2ccb backups: add backup multiple targets 2025-07-25 01:30:27 +02:00
Girish Ramakrishnan
931311f11f rename backups to backuptargets 2025-07-24 18:54:10 +02:00
Girish Ramakrishnan
5e456f378b backups: split listing and targets 2025-07-24 18:21:48 +02:00
Johannes Zellner
68a8c964ea If we have app.error we always have an app.error.details object 2025-07-23 15:40:25 +02:00
Johannes Zellner
6c1045c545 error installationState is in the error details 2025-07-23 15:31:25 +02:00
Girish Ramakrishnan
48559d3358 tasks: distinguish runtime crash vs task error in worker 2025-07-18 20:02:06 +02:00
Girish Ramakrishnan
7e0803c4b4 clean up task locks 2025-07-18 18:12:07 +02:00
Girish Ramakrishnan
0fa281083e apps: backup is not a state anymore
this is launched as a separate task
2025-07-18 14:14:54 +02:00
Girish Ramakrishnan
989d843fcb shell: make shell.sudo promise based and waitable 2025-07-16 22:04:24 +02:00
Girish Ramakrishnan
313256adff use @cloudron/manifest-format 2025-07-10 11:17:04 +02:00
Girish Ramakrishnan
6f4a3701e7 apps: clear updateInfo on successful submit 2025-06-26 17:08:14 +02:00
Girish Ramakrishnan
19c9d7d59d updateInfo: move updateInfo into apps table
this has many advantages:
* easy to deliver the updateInfo via the apps object
* after updating, the task can clear it
* when apps are deleted, the info is automatically gone

otherwise, it's a mess of deps between apps/updater/apptask/rest routes

box update info is still in a file
2025-06-26 15:47:15 +02:00
Girish Ramakrishnan
abd640d36b merge updatechecker into updater 2025-06-26 14:00:30 +02:00
Girish Ramakrishnan
84297ff473 updater: move app update logic and attach the manual update reason 2025-06-20 22:08:02 +02:00
Girish Ramakrishnan
d7fdfd6d71 attach app updateInfo to app object 2025-06-20 18:51:12 +02:00
Girish Ramakrishnan
c44926c2cd redis: disable by default when optional
this simply increases complexity of local setups since redis is
only used as a cache and not for persistent data
2025-06-14 10:40:48 +02:00
Girish Ramakrishnan
811cc9c028 turn: reduce the exposed ports to 100 2025-06-04 13:23:47 +02:00
Girish Ramakrishnan
c0f0084e56 metrics: add stream api for system info 2025-05-21 18:09:02 +02:00
Johannes Zellner
b8dcfcf900 Remove app purchase/unpurchase 2025-05-13 11:46:13 +02:00
Girish Ramakrishnan
3d31f73453 add missing await 2025-02-17 18:38:20 +01:00