i installer django (1,11) et Python 3.5 et virtualenv dans mon CentOS serveur de production (CentOS 6.5)Django sur Apache 2.2.15 sur CentOS 6.5
quand je commence django localement runserver python manage.py je peux utiliser le django, mais je ne peux pas servir mon django sur apache avec mod_wsgi i Test de configuration très différence sur /conf.s/django.conf mais je face à cette erreur:
mod_wsgi (pid=5713): Target WSGI script '/var/www/path/to/site/myapp/wsgi.py' cannot be loaded as Python module.
ceci est mon django.conf dans /etc/httpd/conf.d/django.conf
<VirtualHost *:80>
WSGIProcessGroup myapp
WSGIDaemonProcess myapp display-name=%{GROUP}
ServerName test.com
ServerAlias www.test.com
ServerAdmin [email protected]
DocumentRoot /path/to/root
WSGIScriptAlias//path/to/root/myapp/wsgi.py
Alias /static /path/to/root/myapp/static
ErrorLog /path/to/error.log
CustomLog /path/to/access.log combined </VirtualHost>
comment puis-je résoudre ce problème?
Comment avez-vous installé mod-wsgi? Il doit être compilé avec une certaine version de Python. Si vous yum installé, je suppose que vous avez une version très démodée de Python 2 de yum. – FlipperPA
Oui, le wsgi a été installé avec yum, comment puis-je compiler wsgi pour python 3.5? – Arash