I am trying to build a storage server with rclone on S3 with a sftp gateway and an encryption layer.
And I realized that, unlike Google Drive, when you are deleting a file on such a system, you lost it forever, and there is no way you can recover it if the deletion is a misoperation.
Is it possible to create a trash provider that moves files into a trash directory when they are deleted?
For example, when path-to-file is deleted, the file is actually moved to .trash/path-to-file/timestamp, and you will have a chance to manually recover it until you use cleanup command.
Hi!
Thank you for letting me know!
I tried to search for it on this forum and among GitHub Issues, but most of them are about the trash can of Google Drive.
I'll try again.
On encrypted S3, I think.
I wish it could work on another provider specified in the config like what cache and crypt do.
The idea is that trash layer should be transparent for most of the actions to its next layer except deletion out of trash dir.
When a file out of trash dir is deleted, it should convert the deletion to a move action and apply it on its next layer.
Oh I didn't know that...
I thought move only cost one request on S3 (within the same bucket).
It still worth for me though, since most of my files are small and accidentally deleting an entire directory would be super annoying.