Reputation: 81
manage runfcgi host=127.0.0.1 port=8002 maxrequests=200 maxchildren=100 minchildren=4
I started django fcgi in this way. It seems all right in processes monitor. But when I open http://127.0.0.1:8002, it keep runing and no result come out.
manage runserver 127.0.0.1:8002
This method was fine. Does any one knows why?
Upvotes: 1
Views: 718
Reputation: 5591
As explained in the Django docs on FastCGI:
FastCGI is an efficient way of letting an external application serve pages to a Web server. The Web server delegates the incoming Web requests (via a socket) to FastCGI, which executes the code and passes the response back to the Web server, which, in turn, passes it back to the client’s Web browser.
You're trying to connect directly to the FCGI process from your browser, which won't work: you need an FCGI-compliant webserver to handle your request and delegate it to Django.
See the Django docs for a thorough explanation of how to set this up.
Upvotes: 2