Skip to content
Myr

Minor typos and spelling fixed

Before adoption: this commit came in with the history the project adopted, so no landing records it.

According to http://dictionary.cambridge.org/ "webserver" is incorrect, "web server" = correct

authored by Mieszko · committed by Mieszko · parent a1b2736 · Browse files · 1 file+7 added−7 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+7 added−7 removed

  • other:+7 added−7 removed

1 file+7 added−7 removed

modified:docs/deploying/fastcgi.rst+7 added-7 removed
77 unmodified lines
78 SetHandler fastcgi-script79 </Location>80 </VirtualHost>8182These processes will be managed by Apache. If you're using an standalone82These processes will be managed by Apache. If you're using a standalone83FastCGI server, you can use the FastCgiExternalServer directive instead.84Note that in the following the path is not real, it's simply used as an85identifier to other86directives such as AliasMatch::8788 FastCgiServer /var/www/html/yourapplication -host 127.0.0.1:30008990If you cannot set ScriptAlias, for example on an shared web host, you can use90If you cannot set ScriptAlias, for example on a shared web host, you can use91WSGI middleware to remove yourapplication.fcgi from the URLs. Set .htaccess::9293 <IfModule mod_fcgid.c>94 AddHandler fcgid-script .fcgi
72 unmodified lines
167168Installing FastCGI applications on nginx is a bit different because by169default no FastCGI parameters are forwarded.170171A basic flask FastCGI configuration for nginx looks like this::171A basic Flask FastCGI configuration for nginx looks like this::172173 location = /yourapplication { rewrite ^ /yourapplication/ last; }174 location /yourapplication { try_files $uri @yourapplication; }175 location @yourapplication {
18 unmodified lines
194195Running FastCGI Processes196-------------------------197198Since Nginx and others do not load FastCGI apps, you have to do it by198Since nginx and others do not load FastCGI apps, you have to do it by199yourself. `Supervisor can manage FastCGI processes.200<http://supervisord.org/configuration.html#fcgi-program-x-section-settings>`_201You can look around for other FastCGI process managers or write a script202to run your `.fcgi` file at boot, e.g. using a SysV ``init.d`` script.
6 unmodified lines
209210Debugging211---------212213FastCGI deployments tend to be hard to debug on most webservers. Very213FastCGI deployments tend to be hard to debug on most web servers. Very214often the only thing the server log tells you is something along the215lines of "premature end of headers". In order to debug the application216the only thing that can really give you ideas why it breaks is switching217to the correct user and executing the application by hand.218219This example assumes your application is called `application.fcgi` and220that your webserver user is `www-data`::220that your web server user is `www-data`::221222 $ su www-data223 $ cd /var/www/yourapplication224 $ python application.fcgi
3 unmodified lines
228229In this case the error seems to be "yourapplication" not being on the230python path. Common problems are:231232- Relative paths being used. Don't rely on the current working directory232- Relative paths being used. Don't rely on the current working directory.233- The code depending on environment variables that are not set by the234 web server.235- Different python interpreters being used.236
4 unmodified lines