andyish
a day ago
All systems should have an upper limit harder to them, it's not that hard to implement and it's just an ultimate safeguard.
In the backend, limit image size to say 50mb, the number of images a user can upload to 1k and the amount of users that can be signed up to 10k. Then you have some numbers which will let you say "regardless of what happens, I've got a hard cap of 1 TB of stored data".
You don't have to show the user their usage and you can always lift the caps with a deployment. What you don't want to happen is a side-project costs you tens of thousands because one fool thought it was funny to upload a million hi-res pictures of Rick Astley while you were asleep.
Slightly more work would be to limit the number of images that a user can upload in 15 minutes. Or depending on what your signup flow is making a user confirm their email but putting a short delay in sending the email out.
cyjackx
19 hours ago
Yeah, for me <5MB per pic uploaded (and then compressed) and 5-10 images limit per user should be sufficient to start. That, or some platform specific things like you only get to 1 upload per 10 votes...
Good reminder to set usage caps with a deployment