I am having problems migrating a django site from Ubuntu to CentOS 6.3. When I run the site I get Internal Server Error error from apache, and looking in the logs I get
ImportError: Could not import settings 'soloe_settings' (Is it on sys.path?): No module named soloe_settings
If I put
raise Exception(sys.path) on the end of my wsgi file I get
Exception: ['/usr/lib64/python26.zip', '/usr/lib64/python2.6', '/usr/lib64/python2.6/plat-linux2', '/usr/lib64/python2.6/lib-tk', '/usr/lib64/python2.6/lib-old', '/usr/lib64/python2.6/lib-dynload', '/usr/lib64/python2.6/site-packages', '/usr/lib/python2.6/site-packages', '/srv/Projects/at_estable', '/srv/Projects/at_estable', '/srv/Projects/at_estable']
So Clearly it is on the path.
This is my apache config site in /etc/httpd/conf.d/wsgi.conf http://pastebin.ca/2310660
The first problem I noticed was that I had to put the
LoadModule wsgi_module modules/mod_wsgi.so and
WSGISocketPrefix /var/run/wsg/ lines (never had to do this with Ubuntu Server)
This is my wsgi file in /srv/Projects/at_estable/soloe.wsgi http://pastebin.ca/2310664
My django settings file is in /srv/Projects/at_estable/soloe_settings.py
apache and mod_wsgi where insalled by typing
yum install httpd,
yum install mod_wsgi and using python 2.6 version that already comes with CentOS.
Any ideas on this?