Answer the question
In order to leave comments, you need to log in
How to specify "external directory" as file storage?
Hello everyone
Plz tell me How to specify the "external directory" as the file storage?
Clarification\example:
there is img:
<img src="/static/filestorage/dart.jpg" alt="Письма мастера дзен">
Answer the question
In order to leave comments, you need to log in
1. ln -s /var/filestorage /home/user/project_name/app/static/filestorage
2. specify the required location in nginx (or other web server):
location /filestorage {
root /var;
}
Maybe this can help you:
flask.pocoo.org/docs/0.11/api/#flask.send_from_dir...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question