我有这个错误:
无效命令‘uWSGISocket’,可能是拼写错误或由服务器配置中未包含的模块定义
<VirtualHost *:80>
ServerAdmin [email protected]
ServerName voorloopnul.com
ServerAlias www.voorloopnul.com
DocumentRoot /var/www
<Directory />
Options FollowSymLinks Indexes
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
<Location />
Options FollowSymLinks Indexes
SetHandler uwsgi-handler
uWSGISocket 127.0.0.1:3031
</Location>
<Location /static>
SetHandler none
</Location>
Alias /static //srv/apps/voorloopnul/voorloopnul/static/
ErrorLog ${APACHE_LOG_DIR}/error.log
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/voorloopnul.com.access.log combined
</VirtualHost>
完整教程:http://voorloopnul.com/blog/setting-up-django-with-apache-and-uwsgi-ubuntu-12-10/
答案1
看来你忘记使用 a2enmod 启用模块 libapache2-mod-uwsgi