Merge pull request #16 from cwarden/per-location-proxy-read-timeout
Add per-location proxy read timeout parameter
This commit is contained in:
commit
6cbefd7144
3 changed files with 41 additions and 35 deletions
|
@ -10,6 +10,7 @@
|
|||
# [*index_files*] - Default index files for NGINX to read when traversing a directory
|
||||
# [*proxy*] - Proxy server(s) for a location to connect to. Accepts a single value, can be used in conjunction
|
||||
# with nginx::resource::upstream
|
||||
# [*proxy_read_timeout*] - Override the default the proxy read timeout value of 90 seconds
|
||||
# [*ssl*] - Indicates whether to setup SSL bindings for this location.
|
||||
# [*option*] - Reserved for future use
|
||||
#
|
||||
|
@ -30,6 +31,7 @@ define nginx::resource::location(
|
|||
$www_root = undef,
|
||||
$index_files = ['index.html', 'index.htm', 'index.php'],
|
||||
$proxy = undef,
|
||||
$proxy_read_timeout = $nginx::params::nx_proxy_read_timeout,
|
||||
$ssl = false,
|
||||
$option = undef,
|
||||
$location
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
# [*index_files*] - Default index files for NGINX to read when traversing a directory
|
||||
# [*proxy*] - Proxy server(s) for the root location to connect to. Accepts a single value, can be used in
|
||||
# conjunction with nginx::resource::upstream
|
||||
# [*proxy_read_timeout*] - Override the default the proxy read timeout value of 90 seconds
|
||||
# [*ssl*] - Indicates whether to setup SSL bindings for this vhost.
|
||||
# [*ssl_cert*] - Pre-generated SSL Certificate file to reference for SSL Support. This is not generated by this module.
|
||||
# [*ssl_key*] - Pre-generated SSL Key file to reference for SSL Support. This is not generated by this module.
|
||||
|
@ -41,6 +42,7 @@ define nginx::resource::vhost(
|
|||
$ssl_cert = undef,
|
||||
$ssl_key = undef,
|
||||
$proxy = undef,
|
||||
$proxy_read_timeout = $nginx::params::nx_proxy_read_timeout,
|
||||
$index_files = ['index.html', 'index.htm', 'index.php'],
|
||||
$www_root = undef
|
||||
) {
|
||||
|
@ -82,6 +84,7 @@ define nginx::resource::vhost(
|
|||
ssl => $ssl,
|
||||
location => '/',
|
||||
proxy => $proxy,
|
||||
proxy_read_timeout => $proxy_read_timeout,
|
||||
www_root => $www_root,
|
||||
notify => Class['nginx::service'],
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
location <%= location %> {
|
||||
proxy_pass <%= proxy %>;
|
||||
proxy_read_timeout <%= proxy_read_timeout %>;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue