| Syntax: | fastcgi_catch_stderr |
|---|---|
| Default: | — |
| Context: | http, server, location |
Sets a string to search for in the error stream of a response received from a FastCGI server. If the string is found then it is considered that the FastCGI server has returned an invalid response. This allows handling application errors in nginx, for example:
location /php {
fastcgi_pass backend:9000;
...
fastcgi_catch_stderr "PHP Fatal error";
fastcgi_next_upstream error timeout invalid_header;
}
Please login to continue.