-
-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom directory path per source #441
Comments
Thanks for the comments! This has been discussed in a couple of over overlapping or duplicate issues, but in answer to your specific questions:
While you can use symlinks, usually a cleaner way is to use container volume mounts for additional flexibility on mapping to the host. |
Currently it informs me that I can’t use any directory outside of /downloads and that’s the underlying issue. Sure I can use mounts, symlinks and what not to redirect /downloads/video/{source} to any directory but if I specify a custom directory, or activate a checkbox (use custom directory) it would be nice to not have to use /downloads/video but directly /my/custom/path/{source} |
If you're downloading inside of a container why does the initial directory prefix matter? |
Imagine you have three different storage endpoints. Now I have to mount all three of them as /downloads/video/A, /downloads/video/B and /downloads/video/C, on top of that I have to remember that when I add a source to add the full path /downloads/video/A/custom/directory/{source}. Would be cleaner if I can do /A/custom/directory/{source} |
Surely you would need to create three volume mounts, one for each storage endpoint You should be able to specify a directory like I can't see me reworking the entire file storage system to accommodate completely arbitrary custom file system roots just to remove the |
/downloads/video/my/directory/{source}, works already, all I thought would make sense to allow anything outside of /downloads/video 😊, that’s only an if statement maybe even with a checkbox to only allow directories outside of /downloads/video for “experts”.
|
I believe the custom directory paths are currently slightly broken (some metadata doesn't get downloaded to the right directory, automatic deletion doesn't work in some cases etc.). It's not an official feature I would suggest yet, but if it works for you that's great. The logic is way more complicated than a tick box and involves a defined file system storage inside of the Django framework: https://github.com/meeb/tubesync/blob/main/tubesync/sync/models.py#L26 docs: https://docs.djangoproject.com/en/4.2/ref/files/storage/ While you can change To support multiple file system storage areas it would be significant work, Django file fields don't support multiple storage systems and file storage systems don't support multiple locations so this would require a lot of bug prone, flaky internal hacking of Django to support. In short, it's extremely complicated and I'm certainly not going to add it. |
First of all: Thank you for providing FOSS, you are a part of the people who make the world a better place by providing free solutions to niche problems, thank you.
Would it be possible to add a custom directory path for each source? /downloads/video/{NAME} is too static, it would be nice that we can use any directory path we like “/youtube/science/{NAME}”, “/news/videos/{NAME}” and so on? I know I can “ln -s /downloads/video” to any root directory I want, but it would be nice if this step is not needed. Maybe even allow the use of variables in the name like for the file name “/your/custom/path/{yyyy}/{source}”. Like this we can also place media on different servers via different mounts. Thanks!
The text was updated successfully, but these errors were encountered: