deployment - Stuck with deploying django with apache + mod_wsgi -


i 500 internal server error , in log files writes:

[thu jun 14 16:30:22 2012] [error] [client 127.0.0.1] importerror: not import settings 'mysite.settings' (is on sys.path?): no module named mysite.settings 

here httpd.conf:

servername localhost  <virtualhost *:80>     serveradmin ttt@mysite.com     servername mysite.com     serveralias www.mysite.com     documentroot /var/www/mysite/     loglevel warn     wsgidaemonprocess processes=2 maximum-requests=500 threads=1     wsgiscriptalias / /var/www/mysite/mysite/wsgi.py     alias /media /var/www/mysite/mysite/static/media/ </virtualhost> 

wsgi.py:

import os  os.environ.setdefault("django_settings_module", "mysite.settings") django.core.wsgi import get_wsgi_application application = get_wsgi_application() 

this problem covered in both mod-wsgi documentation http://code.google.com/p/modwsgi/wiki/integrationwithdjango , django deployment documentation https://docs.djangoproject.com/en/1.4/howto/deployment/wsgi/modwsgi/ note project must on python path. can use wsgipythonpath directive or set python-path in wsgidaemonprocess directive django documentation. or can add sys.path in wsgi file mod-wsgi docs state.


Comments

Popular posts from this blog

django - How can I change user group without delete record -

java - Need to add SOAP security token -

java - EclipseLink JPA Object is not a known entity type -