[Python] The STATICFILES_DIRS setting should not contain the STATIC_ROOT setting

Discussão em 'Python' iniciado por Stack, Março 9, 2025.

  1. Stack

    Stack Membro Participativo

    I'm using Django 1.7. When deploying my site to a Production server and running collectstatic, I get following error message:


    django.core.exceptions.ImproperlyConfigured: The STATICFILES_DIRS setting should not contain the STATIC_ROOT setting
    ​

    I use split settings; my production local.py contains:

    STATIC_ROOT = '/home/username/projects/site/static/'


    and my base.py contains:

    STATICFILES_DIRS = (
    os.path.join(BASE_DIR, 'static'),
    )

    Continue reading...

Compartilhe esta Página