-
Notifications
You must be signed in to change notification settings - Fork 28
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
setup buckets for file-uploads #503
Conversation
`ViewRuntime.run_cleanup_hook` already runs in a thread. Signed-off-by: Florian Scherf <mail@florianscherf.de>
Signed-off-by: Florian Scherf <mail@florianscherf.de>
Signed-off-by: Florian Scherf <mail@florianscherf.de>
Signed-off-by: Florian Scherf <mail@florianscherf.de>
Signed-off-by: Florian Scherf <mail@florianscherf.de>
Signed-off-by: Florian Scherf <mail@florianscherf.de>
Signed-off-by: Florian Scherf <mail@florianscherf.de>
This id is intended to be used as identifier for sub-systems like channels or buckets. Signed-off-by: Florian Scherf <mail@florianscherf.de>
This shortcut is intended to make type checks and documentation more readable. Signed-off-by: Florian Scherf <mail@florianscherf.de>
Signed-off-by: Florian Scherf <mail@florianscherf.de>
Codecov ReportAttention:
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #503 +/- ##
==========================================
+ Coverage 73.04% 73.19% +0.14%
==========================================
Files 85 88 +3
Lines 5869 6103 +234
Branches 1275 1326 +51
==========================================
+ Hits 4287 4467 +180
- Misses 1314 1355 +41
- Partials 268 281 +13
☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @fscherf , as far as I can tell: It looks good :-)
Two things I found:
- Is there a way to set the upload limit? Currently
lona_dopzone
limits the size to 250MB. - Maybe it's a good idea to have a settings to disable the management-interface for a bucket by default? I guess most of the time it's not needed.
Once it's merged I will integrate it into one of my projects to see, how it behaves there.
Hi @SmithChart, nice! Thanks for testing and reviewing! :) Both is already implemented. Buckets have the arguments lona-dropzone supports all of these arguments, and you can feed an pre-configured bucket in it. 9361ac5#diff-e6778aa47b2825caf9510d3808762cea575cd372d680e4437970f925c284e35cR62 |
That's an option. But consider the following situation: Let's assume we are working on a project that is, later on, intended to be public-facing (without any authentication). And: If the setting would default to "off", this would be a bit more secure by default. |
I thought about that too and I am still not sure about the security aspect of the index page. On the one hand, I agree, it feels more "secure" not to have that on in production, but on the other hand, it does not allow you anything you can't do using curl or wget. The file and size limits also apply to the index page. |
@SmithChart |
Totally right. A user could extract the token by hand and do the same. |
@SmithChart: I don't think so. I think it is reasonably secure like this |
OK. From my side: Feel free to merge this :-) |
@SmithChart: Great! Thanks for your help and patience :) |
This PR adds a new subsystem called
Buckets
which can be used to upload files or to make files accessible via HTTP