title: Configuring Django runserver to serve static files in a non-app directory?
body: <p>I'm trying to configure Django to serve static files when using <em>runserver</em> (production works fine). Everything works fine for all of the static files that are under an apps directory. The problem comes with static files that are not under a specific app, but are in the final <em>static</em> directory. For instance, I have this project structure:</p>
  
  <pre><code>/myproject/
  /myproject/static/
  /myproject/static/css/foo.css
  /myproject/app1
  /myproject/app1/static/css/bar.css
  
  urls.py
  if settings.SERVE_STATIC:
      urlpatterns += patterns('',
          url(r'^static/(?P&lt;path&gt;.*)$', 'django.views.static.serve',
              {'document_root': settings.STATIC_ROOT}),
      )
      urlpatterns += staticfiles_urlpatterns() # one of these may be redundant.
  
  settings.py
  SERVE_STATIC = True
  PROJECT_ROOT = '/myproject'
  STATIC_ROOT = os.path.join(PROJECT_ROOT, 'static')
  STATIC_URL = '/static/'
  STATICFILES_DIRS = (os.path.join(PROJECT_ROOT, 'static'),)
  INSTALLED_APPS = ('app1',)
  </code></pre>
  
  <p>With these settings, I get the error:</p>
  
  <blockquote>
    <p>ImproperlyConfigured: The STATICFILES_DIRS setting should not contain
    the STATIC_ROOT setting</p>
  </blockquote>
  
  <p>Which makes sense. I'm telling Django to collect static files, and put them in the same place - which could cause a loop.</p>
  
  <p>If I comment out the STATICFILES_DIRS variable, django will find the static file 'bar.css'. But it does <em>not</em> find 'foo.css'.</p>
  
  <p>If I comment out the STATIC_ROOT variable and put back the STATICFILES_DIRS, then it finds the file 'foo.css' - but of course, the 'collectstatic' command will no longer work.</p>
  
  <p>Note - I realize that the '/static' directory is supposed to be empty, but the project I'm on, has files there anyway. :) As long as they're not overwritten by 'collectstatic', it looks like Django runserver should serve them - but it doesn't.</p>
  
  <p>How do I serve the static files under STATIC_ROOT (such as foo.css) when running Django runserver?</p>