title: Moving my Django project on DreamHost (error importing passenger_wsgi.py)
body: <p>I am trying to move my Django project to DreamHost.
  I have created a virtualenv copied my project into the virtualenv on DreamHost server and installed all the dependency.</p>
  
  <p>I created a passenger_wsgi.py file </p>
  
  <pre><code>import sys, os
  cwd = os.getcwd()
  sys.path.append(cwd)
  sys.path.append('/home/user/site/app_name')
  sys.path.append('/home/user/site/project_name')
  sys.path.append('/home/user/python/bin/')
  sys.path.append('/home/user/python/lib/python2.7/site-packages')
  sys.path.append('/home/user/python/lib/python2.7/site-packages/django')
  
  
  #Swithch to new Python
  INTERP = os.path.join(os.environ['HOME'], 'python', 'bin', 'python')
  if sys.executable != INTERP:os.execl(INTERP, INTERP, *sys.argv)
  
  os.environ['DJANGO_SETTING_MODULE'] = 'project.settings'
  import django.core.handlers.wsgi
  application = django.core.handlers.wsgi.WSGIHandler()
  </code></pre>
  
  <p>When I try to visit my site through the browser I get a error:</p>
  
  <p>Getting an internal server error (500)<br>
  error.logs <br>
  Premature end of script headers: admin
  Premature end of script headers: internal_error.html<br></p>
  
  <p>access.logs<br>
  "GET / HTTP/1.1" 500 687 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.116 Safari/537.36"</p>