Girish Ramakrishnan
241053e1a8
s3: error handling has changed in v3 api
2025-06-20 16:07:21 +02:00
Girish Ramakrishnan
48bf21a537
s3: use listObjectsV2 API
...
in some minio instances, listObjectV1 is not returning all the objects
2025-05-26 14:17:13 +02:00
Girish Ramakrishnan
65f066d391
sshfs: implement rm via ssh
...
this is similar to change we did for cp -r . sshfs is often flaky with lots
of concurrent operations
2025-04-09 15:48:53 +02:00
Girish Ramakrishnan
20a30b303b
s3: fix encoding of downloaded stream
2025-02-13 19:29:07 +01:00
Girish Ramakrishnan
59721a3f1a
s3: in v3, Body is a stream
...
https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/migrate-s3.html
2025-02-13 15:17:48 +01:00
Girish Ramakrishnan
cb6d531300
storage: automatically abort old multipart uploads in s3
2025-02-13 11:09:15 +01:00
Girish Ramakrishnan
a138425298
storage: start migration of s3 api
2025-02-12 23:04:37 +01:00
Girish Ramakrishnan
9888aa8c08
storage: rework listDir api to be a generator (like) function
2025-02-12 19:34:57 +01:00
Girish Ramakrishnan
23d91c7b37
upgrade readdirp
2025-02-05 15:50:10 +01:00
Girish Ramakrishnan
837d5803c8
backups: add preserve attributes checkbox
2025-01-24 13:59:01 +01:00
Girish Ramakrishnan
b4d58f0609
aws: add a 20min timeout
...
in some services like b2, the multi-part copy just hangs. this allows
us to retry
2024-11-20 07:13:43 +05:30
Girish Ramakrishnan
6407d795ed
du: better error handling of du
...
du can fail when files and directories go missing. luckily, when du fails,
it still provides the best effort output
2024-11-06 14:54:52 +01:00
Girish Ramakrishnan
6c3ca9c364
shell: rework code to use shell.spawn
...
spawn gives out streams and we have more control over the stdout/stderr
buffers. otherwise, we have to provide a max buffer capture size to exec
2024-10-15 12:13:46 +02:00
Girish Ramakrishnan
a9e1d7641d
shell: make require take a tag
2024-10-14 21:08:32 +02:00
Girish Ramakrishnan
ea72cef7f9
storage: remove getProviderStatus
2024-09-09 17:36:51 +02:00
Girish Ramakrishnan
1cd577cc65
filesystem: remove debug warning
2024-09-08 15:25:49 +02:00
Girish Ramakrishnan
4a29371907
s3: sometimes message is null and only code is valid
2024-08-13 07:08:33 +02:00
Girish Ramakrishnan
041f7da59b
backups: make noop upload work again
2024-08-12 10:05:14 +02:00
Girish Ramakrishnan
247309e11b
use constant
2024-07-30 11:00:50 +02:00
Girish Ramakrishnan
b26ff08a3c
shell: copy over code and signal values from cp object
2024-07-22 21:24:27 +02:00
Girish Ramakrishnan
44678cf5f1
sshfs: if remote copy fails, fallback to sshfs based copy
...
remote copy can file if there is no cp in the remote . for example,
if it was a windows server.
2024-07-22 20:53:19 +02:00
Girish Ramakrishnan
e9b6002f63
s3: fix exists check
2024-07-14 22:04:12 +02:00
Girish Ramakrishnan
ad4e0ba9aa
tests: fix storage test
2024-07-08 22:29:45 +02:00
Girish Ramakrishnan
1dc6b40a68
tgz: extract using tar-stream directly
...
we used have a fork of tar-fs. using tar-stream directly gives us
more control
2024-07-08 13:06:56 +02:00
Johannes Zellner
d122ece8e9
Attempt server side copy on sshfs via ssh exec
...
only so far tested agains hetzner storage boxes which apparently run BSD
unix tools
2024-07-02 19:51:34 +02:00
Girish Ramakrishnan
e481606d0e
lint
2024-07-02 16:09:36 +02:00
Girish Ramakrishnan
2b1b304c6e
backup/import/restore: fix crash with root path calcuation
...
rootPath was calculated before the arguments were validated
2024-04-09 13:53:48 +02:00
Girish Ramakrishnan
a6f078330f
shell: no need to promise scoping
2024-02-21 19:40:27 +01:00
Girish Ramakrishnan
cfd5c0f82b
shell: rewrite exec to use execFile
...
this also renames execFile to execArgs
2024-02-21 18:54:43 +01:00
Girish Ramakrishnan
2237d2bbb7
shell: remove usage of .spawn
2024-02-21 13:27:04 +01:00
Girish Ramakrishnan
54c7757e38
Fix crash
2024-02-20 21:53:52 +01:00
Girish Ramakrishnan
3da3ccedcb
volumes: only wait for 5 seconds for mount status
...
mountpoint -q can never exit if the nfs mount disappears, for example
2024-02-20 21:38:57 +01:00
Girish Ramakrishnan
243a254f3e
filesystem: remove hook should not rm recursively
...
this causes a bug in the backupcleaner when it tries to prune
empty directories when using the filesystem backend.
the bug is hit when a box backup is getting cleaned up but
one or more app backups are preserved.
2024-01-25 11:50:48 +01:00
Girish Ramakrishnan
934c701be2
vultr: fix copy of large objects
...
https://forum.cloudron.io/topic/10266/backups-are-failing
2023-10-26 09:51:07 +02:00
Girish Ramakrishnan
aa8c23c8b3
rework backup root
...
notes:
* backup root cannot come from backend. for dynamic mounts backend cannot know where it is mounted
* backupConfig is 3 parts - format / mount / password . there is also this rootPath (which should not be in db)
* password should be stored separately in settings at some point
* format has to be passed along everywhere because we allow restore from same backupConfig but different format. we do this by saving the format in the backups table
fixes #819
2023-08-15 22:51:45 +05:30
Girish Ramakrishnan
e6b85c2df7
remount does not need a backend hook
2023-08-15 08:55:38 +05:30
Johannes Zellner
10646e9e04
Add generic disk (partition) backup provider to replace ext4 and xfs
2023-08-08 15:11:22 +02:00
Girish Ramakrishnan
3d5c21d9ca
backups: encrypted backups must have .enc extension
2023-07-24 22:25:06 +05:30
Girish Ramakrishnan
050a82039a
getBackupProviderStatus -> getProviderStatus
2023-07-15 11:00:45 +05:30
Girish Ramakrishnan
c86059e070
backups: move limits into a sub object
...
fixes #817
2023-07-13 12:17:57 +05:30
Girish Ramakrishnan
4a1cdd4ef1
Update aws-sdk and suppress maintenance mode message
...
https://github.com/aws/aws-sdk-js/issues/4354
2023-05-11 22:18:00 +02:00
Girish Ramakrishnan
c4f4f3e914
logs: use %o to format error
...
otherwise, they are printed as multi-line and this messes up tail+date formatting
2023-04-16 10:49:59 +02:00
Girish Ramakrishnan
093fc98ae5
s3: add listing check
...
This is needed for situations like in cloudflare where the endpoint can
be mistakenly configured with the bucket name like https://xx.r2.cloudflarestorage.com/cloudron-backups .
The upload and del calls work but list and copy does not.
2023-01-17 11:13:03 +01:00
Girish Ramakrishnan
40bcfdba76
s3: throw any copy errors
2023-01-17 11:00:03 +01:00
Girish Ramakrishnan
8a5d4e2fb0
better debugs
2022-11-05 08:43:02 +01:00
Girish Ramakrishnan
17c7cc5ec7
Remove external df module
...
It has some parsing issues with locale
2022-10-18 19:56:18 +02:00
Girish Ramakrishnan
c3793da5bb
split checkPrecondition so it can be used in cleaner as well
2022-10-02 17:41:21 +02:00
Girish Ramakrishnan
4f4a0ec289
use mount code to check mount status
2022-10-02 16:51:03 +02:00
Girish Ramakrishnan
56b981a52b
backups: when checking mount status, ignore the prefix
2022-10-02 16:33:04 +02:00
Girish Ramakrishnan
074e9cfd93
rename getRootPath to getBackupRootPath
2022-10-02 16:26:27 +02:00