mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-04-25 17:25:57 +03:00
[PR #2605] [MERGED] Fall back to move_copy_to if persist_to fails while saving uploaded files. #3119
Labels
No labels
SSO
Third party
better for forum
bug
bug
documentation
duplicate
enhancement
future Vault
future Vault
future Vault
good first issue
help wanted
low priority
notes
pull-request
question
troubleshooting
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/vaultwarden#3119
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/dani-garcia/vaultwarden/pull/2605
Author: @ruifung
Created: 7/8/2022
Status: ✅ Merged
Merged: 7/15/2022
Merged by: @dani-garcia
Base:
main← Head:main📝 Commits (5)
ebe9162Add option to make file uploads use move_copy_to instead of persist_to5c38b2cRemove option and use unwrap_or_else to fall back to copy behavior.3159588Use match to avoid ownership issues on the TempFile / file_path variables in closures.84bcac0Apply rustfmt.bf623eeUse if let instead of a match with empty block.📊 Changes
2 files changed (+13 additions, -7 deletions)
View changed files
📝
src/api/core/ciphers.rs(+9 -6)📝
src/api/core/sends.rs(+4 -1)📄 Description
This is to support scenarios where the attachments and sends folder are to be stored on a separate device from the tmp_folder (i.e. fuse-mounted S3 storage), due to having the tmp_dir on the same device being undesirable.
Example being fuse-mounted S3 storage with the reasoning that because S3 basically requires a copy+delete operations to rename files, it's inefficient to rename files on device, if it's even allowed.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.