title: Heroku - Handling static files in Django app
body: <p>I have a project (myapp) in heroku but I can't get the static files to work properly. I was following this <a href="http://matthewphiong.com/managing-django-static-files-on-heroku">blog post</a>.</p>
  
  <p>My <code>Procfile</code> looks like this:</p>
  
  <pre><code>web: python myapp/manage.py collectstatic --noinput; bin/gunicorn_django --workers=4 --bind=0.0.0.0:$PORT myapp/settings.py
  </code></pre>
  
  <p><code>settings.py</code>:</p>
  
  <pre><code>...
  
  STATIC_ROOT = os.path.join(PROJECT_PATH, 'staticfiles')
  STATIC_URL = '/static/'
  ADMIN_MEDIA_PREFIX = '/static/admin/'
  
  STATICFILES_DIRS = (
      # I have the static folder inside my app and not inside the project
      os.path.join(PROJECT_PATH, 'cesar/static'),
  )
  
  ...
  </code></pre>
  
  <p>When restarting using <code>heroku restart</code> this is what the <code>heroku logs</code> shows:</p>
  
  <pre><code>...
  Copying ...
  
  114 static files copied to '/app/myapp/staticfiles'.
  ...
  </code></pre>
  
  <p>But when I do <code>heroku run ls -l myapp/</code> I can't see the <code>staticfiles</code> folder:</p>
  
  <pre><code>-rw------- 1 u5605 5605    0 Jan 28 16:53 __init__.py
  drwx------ 4 u5605 5605 4096 Jan 28 16:53 cesar
  -rw------- 1 u5605 5605  503 Jan 28 16:53 manage.py
  -rw------- 1 u5605 5605 6292 Jan 28 16:53 settings.py
  drwx------ 2 u5605 5605 4096 Jan 28 16:53 templates
  -rw------- 1 u5605 5605  257 Jan 28 16:53 urls.py
  -rw------- 1 u5605 5605  286 Jan 28 16:53 views.py
  </code></pre>
  
  <p>What am I missing or doing wrong?</p>