title: Deploying Django To Heroku - Server Error (500)
body: <p>I have been making a django app, and am now trying to deploy it to heroku.
  However when I go on it, says <code>Server Error (500)</code>, and the log says: <code>2017-05-27T21:00:14.634310+00:00 heroku[router]: at=info method=GET path="/" host=remberit.herokuapp.com request_id=065d27c6-9211-458f-9fc6-bb677d43581e fwd="86.13.204.65" dyno=web.1 connect=0ms service=151ms status=500 bytes=387 protocol=https</code></p>
  
  <p>Here is my settings.py (at learst the relevant parts, but please ask if you would like the rest):</p>
  
  <pre><code>PROJECT_ROOT = os.path.dirname(os.path.abspath(__file__))
  
  STATIC_ROOT = os.path.join(PROJECT_ROOT, "staticfiles")
  STATIC_URL = '/static/'
  
  STATICFILES_DIRS = (
      os.path.join(BASE_DIR, 'static'),
  )
  
  STATICFILES_STORAGE = 'whitenoise.django.GzipManifestStaticFilesStorage'
  
  import dj_database_url
  
  DATABASES['default'] = dj_database_url.config()
  
  SECURE_PROXY_SSL_HEADER = ('HTTP_X_FORWARDED_PROTO', 'https')
  
  ALLOWED_HOSTS = ['*']
  
  DEBUG = False
  
  try:
      from .local_settings import *
  except ImportError:
      pass
  </code></pre>
  
  <p>And here is my wsgi.py:</p>
  
  <pre><code>import os
  
  from django.core.wsgi import get_wsgi_application
  #from whitenoise.django import DjangoWhiteNoise
  import django
  
  os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'remberit.settings')
  django.setup()
  
  application = get_wsgi_application()
  #application = DjangoWhiteNoise(application)
  </code></pre>
  
  <p>Here is my Procfile:</p>
  
  <pre><code>web: gunicorn remberit.wsgi
  </code></pre>
  
  <p>Here is my runtime.txt:</p>
  
  <pre><code>python-3.5.2
  </code></pre>
  
  <p>Here is my requirements.txt:</p>
  
  <pre><code>appdirs==1.4.3
  dj-database-url==0.4.2
  gunicorn==19.7.1
  packaging==16.8
  pyparsing==2.2.0
  six==1.10.0
  whitenoise==3.3.0
  psycopg2==2.6.2
  </code></pre>
  
  <p>And here is the output of <code>pip freeze</code>: </p>
  
  <pre><code>appdirs==1.4.3
  dj-database-url==0.4.2
  gunicorn==19.7.1
  packaging==16.8
  pyparsing==2.2.0
  six==1.10.0
  whitenoise==3.3.0
  </code></pre>
  
  <p>Also, when I run the app locally with <code>gunicorn remberit.wsgi</code> or <code>python manage.py runserver</code> it works fine, it only doesn't work when I use heroku.</p>
  
  <p>Please tell me if you need anymore information.</p>