This is what I found that in theory should work from git hub.com passenger-pylons-wsgi-example
import os, sys
sys.path.append('/home/user/test.sample.com/Helloworld')
os.environ['PYTHON_EGG_CACHE'] = '/home/user/tmp'
from paste.deploy import loadapp
def application(environ, start_response):
environ['SCRIPT_NAME'] = environ['PATH_INFO']
application = loadapp('config:/home/user/test.sample.com/production.ini')
return application(environ, start_response)
Tried it on dreamhost and I get: An error occurred importing your passenger_wsgi.py
I also tried the virtual environment but it didn't seem to work either.
mind you after following the instructions I have python 2.6 but no activate in the virtual directory.
Any ideas?
I also tried adding:
from fcgi import WSGIServer
and after the def application:
server = WSGIServer(application) server.run()
But still get the same error. I wish it was a bit more descriptive so I could debug the passenger_wsgi