[uWSGI] nginx+uwsgi problem: Can't set empy SCRIPT_NAME param
Andrey Petrov
shazow at gmail.com
Sun Jul 4 03:02:11 CEST 2010
>
> Do you really need dynamic apps ?
>
> To run pylons apps you can simply use:
>
> http://projects.unbit.it/uwsgi/wiki/UsePaste
I tried to set this up using the --paste flag, but I still get "wsgi
application not found".
Here's my uwsgi command:
uwsgi -s /tmp/uwsgi.sock -H /var/lib/wsgi/ --paste
config:/var/lib/wsgi/src/myproject/staging.ini \
--uid 33 --gid 33 -M --pythonpath /var/lib/wsgi/src/myproject --pythonpath
/var/lib/wsgi
I tried various combinations of --pythonpath (with and without and pointing
to different places like /var/lib/wsgi/lib/python-2.6/site-packages and
such).
And the nginx configuration is simply:
location / {
uwsgi_pass unix:///tmp/uwsgi.sock;
include uwsgi_params;
}
Is there anything obvious I'm missing?
Also another problem I've encountered is that my logging configurations in
the .ini are not being respected when I run through uwsgi (as opposed
through paster). For example, in the staging.ini, I have a logger that I
define to write through RotatingFileHandler that I call explicitly with
every request inside of the application but it's not getting written when
running through uwsgi. Any thoughts on this?
Excerpt from staging.ini:
[loggers]
keys = root, history
...
[logger_history]
level = DEBUG
handlers = history
qualname = history
[handler_history]
class = handlers.RotatingFileHandler
args = ('/var/lib/wsgi/src/myproject/history.log','a', 20000000, 10)
level = NOTSET
formatter = simpler
Thank you again and I'm looking forward to your polishing of the nginx uwsgi
params interface (re SCRIPT_NAME). :)
- Andrey
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.unbit.it/pipermail/uwsgi/attachments/20100703/6b82ab47/attachment.htm
More information about the uWSGI
mailing list