Stecken die mit der Bereitstellung von django mit apache + mod_wsgi

Bekomme ich einen 500 internal server error und im log Dateien schreibt er:

[Thu Jun 14 16:30:22 2012] [error] [client 127.0.0.1] ImportError: Could not import settings 'mysite.settings' (Is it on sys.path?): No module named mysite.settings

hier ist meine 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")
from django.core.wsgi import get_wsgi_application
application = get_wsgi_application()
Sie fehlen WSGIProcessGroup. Ihre Anwendung würde nicht delegiert werden an die daemon-Prozess-Gruppe mit, was Sie haben.
NÖ, dass ist nicht das problem... mein sys Weg war das problem
Die sys.der Pfad kann auch Ihr problem, aber Sie sind noch immer fehlt ein WSGIProcessGroup Richtlinie. Siehe code.google.com/p/modwsgi/wiki/...

InformationsquelleAutor Tony Kyriakidis | 2012-06-14

Schreibe einen Kommentar