2011-07-15 85 views
2

我有一個金字塔應用程序和Apache與mod_wsgi,我試圖讓他們一起工作。這裏是我的httpd.conf:不能讓金字塔與mod_wsgi一起工作

ServerRoot "/home/user/webapps/myapp/apache2" 
LoadModule dir_module  modules/mod_dir.so 
LoadModule env_module  modules/mod_env.so 
LoadModule log_config_module modules/mod_log_config.so 
LoadModule mime_module  modules/mod_mime.so 
LoadModule rewrite_module modules/mod_rewrite.so 
LoadModule setenvif_module modules/mod_setenvif.so 
LoadModule wsgi_module  modules/mod_wsgi.so 
LoadModule authz_host_module modules/mod_authz_host.so 

LogFormat "%{X-Forwarded-For}i %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combinedCustomLog /home/user/logs/user/access_myapp.log combined 
ErrorLog /home/user/logs/user/error_myapp.log 
KeepAlive Off 
Listen 41121 
MaxSpareThreads 3 
MinSpareThreads 1 
ServerLimit 1 
SetEnvIf X-Forwarded-SSL on HTTPS=1 
ThreadsPerChild 5 
WSGIApplicationGroup %{GLOBAL} 
WSGIPassAuthorization On 
WSGIDaemonProcess myapp processes=1 display-name=%{GROUP} python-path=/home/user/webapps/myapp/htdocs/lib/python2.4/site-packages/ threads=4 

WSGIScriptAlias//home/user/webapps/myapp/htdocs/pyramid.wsgi 

<Directory /home/user/webapps/myapp/htdocs> 
     WSGIProcessGroup myapp 
     Order allow,deny 
     Allow from all  
</Directory> 

不幸的是,我得到了一個服務器錯誤:Asse田:該EvalException中間件是不是在多進程環境中使用

我跟着this教程,看着this後,但不能真正做到這一點。

謝謝!

回答

1

你必須在你禁用調試模式部署設置