Hi, Trying to understand why I couldn't succesfully upgrade mumble-django app with uwsgi from 1.0.x to 1.2.x (Got "no app loaded" in logs followed by "uwsgi error / Python application not found" in a browser), I tracked it down to the 1.2 init-script being damn wrong: it would totally ignore .wsgi file argument passed to it. Line 81: if [ -n "${UWSGI_PROGRAM}" ]; then OPTIONS="${OPTIONS} --fileserve-mode ${UWSGI_PROGRAM}" fi --fileserve-mode is not the correct option, but --file or --wsgi-file (as in 1.0.x init-script). Fun fact is that --file (fix I used) and --wsgi-file options are actually absent of uwsgi --help text.
Hi El Goretto, Actually the --file and --wsgi-file are present in the --help only if you load the python plugin *before* calling them (it's tricky I know). For example consider the output of the two commands : # uwsgi --help | grep file vs # uwsgi --plugins=python27 --help | grep file As the init script must be right for all plugins use cases, we couldn't rely on the fact that the python one would always be called, that's why we have to use the --fileserve-mode option. In your case, you have to set this in the UWSGI_EXTRA_OPTIONS parameter of the conf.d/uwsgi file. Something like "--plugins=python27 --file /path/to/your/file.py" Hope that is clear and helps ? Keep me posted plz. Cheers
Owwwwww, I see. I'm totally not skilled in uwsgi area. Ok, then --wsgi-file is only used with python plugin. [snip] You mean that depending of the plugin/language loaded, the keyword pointing to uwsgi app ($UWSGI_PROGRAM) is different (only used python so far)? I still don't understand (in init script) how --fileserve-mode is related to $UWSGI_PROGRAM var, since documentation reads that fileserve-mode parameters are: *x-sendfile -> will use the X-Sendfile header (apache, Cherokee, lighttpd) *x-accel-redirect -> will use the X-Accel-Redirect header (nginx) *default -> sendfile() Or the $UWSGI_PROGRAM is definitly not what I think it is (the uwsgi app file). Regards.
(In reply to comment #2) > Owwwwww, I see. > > I'm totally not skilled in uwsgi area. Ok, then --wsgi-file is only used > with python plugin. > [snip] > You mean that depending of the plugin/language loaded, the keyword pointing > to uwsgi app ($UWSGI_PROGRAM) is different (only used python so far)? > > I still don't understand (in init script) how --fileserve-mode is related to > $UWSGI_PROGRAM var, since documentation reads that fileserve-mode parameters > are: > *x-sendfile -> will use the X-Sendfile header (apache, Cherokee, lighttpd) > *x-accel-redirect -> will use the X-Accel-Redirect header (nginx) > *default -> sendfile() > Or the $UWSGI_PROGRAM is definitly not what I think it is (the uwsgi app > file). > > Regards. I'm sure that bug #416959 will enlighten you on this matter [1]. This issue has already been discussed there. If not, don't hesitate to say so. [1] https://bugs.gentoo.org/show_bug.cgi?id=416959
*** This bug has been marked as a duplicate of bug 416959 ***