[prev in list] [next in list] [prev in thread] [next in thread]
List: uwsgi
Subject: [uWSGI] STDIN never closed with CGI and POST
From: Konstantin Ryabitsev <konstantin () linuxfoundation ! org>
Date: 2016-04-22 18:59:42
Message-ID: 20160422185942.GA31201 () gmail ! com
[Download RAW message or body]
[Attachment #2 (multipart/signed)]
Hi, all:
I'm trying to set up uwsgi with cgi plugin and git-http-backend, to
see if we get better performance with uwsgi over fastcgi (http-git
performance is fairly important to us for git.kernel.org).
However, all my attempts have been in vain thus far, because attempting
to clone always hangs -- GETs work just fine, but when we try to do a
POST, git-http-backend enters endless read() and then things time out.
Apparently, this is because STDIN with POST data is never closed.
Here's my configuration:
nginx (version 1.8.1):
-------
server {
root /var/www/html;
server_name git.example.com;
location / {
include uwsgi_params;
uwsgi_modifier1 9;
uwsgi_buffering off;
uwsgi_param GIT_HTTP_EXPORT_ALL "1";
uwsgi_param GIT_PROJECT_ROOT /var/lib/git/repos;
uwsgi_param PATH_INFO $1;
uwsgi_pass 127.0.0.1:10002;
}
}
-------
uwsgi (version 2.0.12):
-------
[uwsgi]
plugins = cgi
uid = apache
gid = apache
post-buffering = 8192
processes = 1
threads = 50
socket = :10002
#cgi = /var/www/cgi-bin/foo
cgi = /usr/libexec/git-core/git-http-backend
logto = /var/log/uwsgi/git-http-backend/uwsgi.log
-------
The "foo" script I've used to narrow things down is as follows:
-------
#!/bin/bash
cat "${1:-/dev/stdin}" > /var/tmp/foo-stdin
# We never get here, it hangs above
echo ";Finished stdin" >> /var/tmp/foo-stdin
# This is here for testing via regular cgi interface with apache
echo "Status: 200 OK"
echo
echo "OK"
-------
Anything I'm doing obviously wrong that STDIN is never closed? Is nginx the
culprit here?
I'm a bit stumped, so any help will be greatly appreciated.
Regards
--
Konstantin Ryabitsev
Linux Foundation Collab Projects
Montréal, Québec
["signature.asc" (application/pgp-signature)]
_______________________________________________
uWSGI mailing list
uWSGI@lists.unbit.it
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic