django 静态文件

MEDIA_ROOT

is the folder where every files uploaded with an FileField will go.

STATIC_ROOT

 is the folder where every static files will be stored after a manage.py collectstatic

The absolute path to the directory where collectstatic will collect static files for deployment.

If the staticfiles contrib app is enabled (default) the collectstatic management command will collect static files into this directory. See the howto on managing static files for more details about usage.

STATICFILES_DIRS

is the list of folder where Django will search for additional static files, in addition to each static folder of each app installed.
This setting defines the additional locations the staticfiles app will traverse if the FileSystemFinder finder is enabled, e.g. if you use the collectstatic or findstatic management command or use the static file serving view.

聚合

python manage.py collectstatic
    原文作者:timger
    原文地址: https://segmentfault.com/a/1190000006714878
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞