Questions tagged [django-staticfiles]

A Django app that provides helpers for serving static files.

django-staticfiles is a Django app that provides helpers for serving static files.

1241 questions
5
votes
3 answers

My link to manifest.json in index.html works when I run react script 'yarn start', but not when I run 'python3 manage.py runserver'

When I run 'yarn start', my link to manifest.json in my index.html file works fine, but when I run 'python3 manage.py runserver' all I get in the terminal is: Not Found: /manifest.json "GET /manifest.json HTTP/1.1" 404 2234 This also happens to all…
AshM
  • 53
  • 1
  • 3
5
votes
1 answer

django collectstatic with django-storages recopying all files

I am using django.contrib.staticfiles along with django-storages for deploying my static files to Amazon S3. The django version that I am using is 1.10.4 and django-storages version is 1.5.2. Now when I run collectstatic, it re-copies all files from…
Divick
  • 1,213
  • 1
  • 20
  • 44
5
votes
1 answer

heroku & django: server doesn't load staticfiles

Last night I decided to put my django school project on production. For this I used Heroku. Everything is going fine but "the last touch" is driving me crazy. It seems that it doesn't see my staticfiles like bootstrap css'es on the website and I…
5
votes
2 answers

ImproperlyConfigured staticfiles

I have deploy simple blog application on Heroku, it run on Django=1.8.4, and I'm having some issues whit static files. When open mine application I see Application Error page, so I have try to debug it and find out that when I commit to Heroku it…
copser
  • 2,523
  • 5
  • 38
  • 73
5
votes
1 answer

Django 1.8 and the ever confusing "Static Files"

I've fired up a new Django 1.8 project and am hitting the wall of trying to serve static files in the development environment. I'm pretty sure I've followed the docs explicitly, but it's just not working. Settings.py STATICFILES_DIR = ( …
Garfonzo
  • 3,876
  • 6
  • 43
  • 78
5
votes
1 answer

Apache is not serving static files from Django app

I don't know what's wrong in my virtualhost for django project but the simply question is no matter what modification I do over this file stills output the same in error log from apache and not load any css or js files, what I can see is that Apache…
Enot
  • 790
  • 2
  • 15
  • 34
5
votes
1 answer

Difference between "load static from staticfiles" and "django.core.context_processors.static" in Django

As I am learning about how Django handles static files, I have seen two different ways of serving static files while still allowing portability. One way is to do the following in the template: {% load static from staticfiles %}
Anthony F.
  • 545
  • 1
  • 5
  • 20
5
votes
2 answers

Why is django's development automatic static file server not suitable for production?

As stated in: https://docs.djangoproject.com/en/dev/howto/static-files/ When DEBUG is set to True, the server automatically serves the static file, but it states: This method is grossly inefficient and probably insecure, so it is unsuitable for…
dl8
  • 1,270
  • 1
  • 14
  • 34
5
votes
1 answer

apache server cant find static files in Django project

I'm trying to upload my code on an apache server using mod_python. I have tried a lot but the server is not able to access my static files (all my images, js and css). Here are my Virtualhost settings: ServerName…
user_2000
  • 1,103
  • 3
  • 14
  • 26
5
votes
1 answer

Django 1.4, checking if a static file exists when DEBUG=True

I'm trying to write some code that checks if a static file exists while in DEBUG mode, and I can't get it working. Here's what I've tried in the console: >> from django.conf import settings >>> settings.DEBUG True >>> from…
leo
  • 339
  • 2
  • 13
5
votes
1 answer

How to use django-cumulus for serving Static files?

I'm trying to use django-cumulus for serving files off Rackspace CloudFiles. I'm currently only trying it on my local dev server, using Django 1.4.2. I can use cumulus's syncstatic management command to upload all my static assets successfully, but…
Phil Gyford
  • 13,432
  • 14
  • 81
  • 143
5
votes
2 answers

Django on Heroku -- static files not being found

I am running Django on Heroku. I can successfully run collectstatic, but when I go to the site it is obvious that Django is unable to find my static files. Here's a snippet from my settings -- I think it's mostly standard stuff: STATIC_ROOT =…
Clay Wardell
  • 14,846
  • 13
  • 44
  • 65
4
votes
1 answer

django admin static files stopped working after upgrade to 1.4

Setting up static files in django has always been a nightmare to me. When it comes to dealing with django static content I get depressed and feel dumb and stupid. I never really cared about getting admin media files served as static ones since I…
abolotnov
  • 4,282
  • 9
  • 56
  • 88
4
votes
1 answer

Django not able to find the static files when using django-allauth

When I use allauth, everything seems to work fine except that Django is now unable to find the static files. Without allauth all the static files are being rendered. the settings for allauth requires to add TEMPLATE_CONTEXT_PROCESSORS = ( …
Sachin
  • 3,672
  • 9
  • 55
  • 96
4
votes
2 answers

Force re-collectstatic with django static?

I need to know if I can "re-collectstatic files" with django static?, for error I deleted a static directory now, I'm trying collectstatic one more time and nothing happen.. Any idea?
Asinox
  • 6,747
  • 14
  • 61
  • 89