S
S
Sobak202020-09-29 11:44:21
Django
Sobak20, 2020-09-29 11:44:21

What is the best way to store images from the webserver side?

Hello,
I am writing a backend for a django site and faced this issue. Let's say on the site each user can upload and store images on it. So what is the best way to store these images?

There was an option to conditionally create a folder for each user on the server / cloud storage and store its images there with database bindings, but it seems to me that this path takes up a lot of memory resources

There was another option, hash / dehash each image in BASE64 and also store it , but here it will most likely be inefficient on the part of server capacities

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dr. Bacon, 2020-09-29
@bacon

You use an ImageField, estimate how much space is required for these images, if there is enough host disk, then use it, if not enough, then S3-like storage.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question