uwsgi_next_upstream_tries

Syntax: uwsgi_next_upstream_tries number; Default: uwsgi_next_upstream_tries 0; Context: http, server, location This directive appeared in version 1.7.5. Limits the number of possible tries for passing a request to the next server. The 0 value turns off this limitation.

proxy_cookie_path

Syntax: proxy_cookie_path off;proxy_cookie_path path replacement; Default: proxy_cookie_path off; Context: http, server, location This directive appeared in version 1.1.15. Sets a text that should be changed in the path attribute of the “Set-Cookie” header fields of a proxied server response. Suppose a proxied server returned the “Set-Cookie” header field with the attribute “path=/two/some/uri/”. The directive proxy_cookie_path /two/ /; will rewrite this attribute to “path=/so

fastcgi_cache_lock

Syntax: fastcgi_cache_lock on | off; Default: fastcgi_cache_lock off; Context: http, server, location This directive appeared in version 1.1.12. When enabled, only one request at a time will be allowed to populate a new cache element identified according to the fastcgi_cache_key directive by passing a request to a FastCGI server. Other requests of the same cache element will either wait for a response to appear in the cache or the cache lock for this element to be released, up to

proxy_ssl_crl

Syntax: proxy_ssl_crl file; Default: — Context: http, server, location This directive appeared in version 1.7.0. Specifies a file with revoked certificates (CRL) in the PEM format used to verify the certificate of the proxied HTTPS server.

uninitialized_variable_warn

Syntax: uninitialized_variable_warn on | off; Default: uninitialized_variable_warn on; Context: http, server, location, if Controls whether warnings about uninitialized variables are logged.

geoip_country

Syntax: geoip_country file; Default: — Context: http Specifies a database used to determine the country depending on the client IP address. The following variables are available when using this database: $geoip_country_code two-letter country code, for example, “RU”, “US”. $geoip_country_code3 three-letter country code, for example, “RUS”, “USA”. $geoip_country_name country name, for example, “Russian Federation”, “United States”.

Controlling nginx

Controlling nginx Changing Configuration Rotating Log-files Upgrading Executable on the Fly nginx can be controlled with signals. The process ID of the master process is written to the file /usr/local/nginx/logs/nginx.pid by default. This name may be changed at configuration time, or in nginx.conf using the pid directive. The master process supports the following signals: TERM, INT fast shutdown QUIT graceful shutdown HUP changing configuration, keeping up with a changed time zone (only for

proxy_buffering

Syntax: proxy_buffering on | off; Default: proxy_buffering on; Context: http, server, location Enables or disables buffering of responses from the proxied server. When buffering is enabled, nginx receives a response from the proxied server as soon as possible, saving it into the buffers set by the proxy_buffer_size and proxy_buffers directives. If the whole response does not fit into memory, a part of it can be saved to a temporary file on the disk. Writing to temporary files is

fastcgi_cache_bypass

Syntax: fastcgi_cache_bypass string ...; Default: — Context: http, server, location Defines conditions under which the response will not be taken from a cache. If at least one value of the string parameters is not empty and is not equal to “0” then the response will not be taken from the cache: fastcgi_cache_bypass $cookie_nocache $arg_nocache$arg_comment; fastcgi_cache_bypass $http_pragma $http_authorization; Can be used along with the fastcgi_no_cache directive.

ssl_client_certificate

Syntax: ssl_client_certificate file; Default: — Context: stream, server This directive appeared in version 1.11.8. Specifies a file with trusted CA certificates in the PEM format used to verify client certificates. The list of certificates will be sent to clients. If this is not desired, the ssl_trusted_certificate directive can be used.