I am deploying my web.py application on Apache2 with mod_wsgi.
Here is my virt_host file,
WSGIPythonPath /home/ubuntu/plotwatt/libplotwatt:/home/ubuntu/plotwatt/pwstage/src
<VirtualHost *:20108>
ServerAdmin gslabrails.dev.plotwatt.com
DocumentRoot /var/www
WSGIScriptAlias / /var/www/currentcost/server.py
WSGIDaemonProcess currentcost user=ubuntu group=ubuntu processes=5 threads=3
WSGIProcessGroup currentcost
WSGIApplicationGroup %{GLOBAL}
AddType text/html .py
<Directory /var/www/currentcost/>
Order deny,allow
Allow from all
</Directory>
ErrorLog /var/log/apache2/currentcost_error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog /var/log/apache2/currentcost_access.log combined
</VirtualHost>
I have given path to my lib named redisStage in WSGIPythonPath. But, it seems to be not working for me. Am i making any wrong configuration? I can't put WSGIPythonPath directive inside VitualHost directive. What must be the reason ?
According to the docs, you cannot use
WSGIPythonPath
when using daemon mode. Use the 'python-path' option to the WSGIDaemonProcess directive instead.