diff options
author | Eric Wong <normalperson@yhbt.net> | 2009-10-09 15:06:44 -0700 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2009-10-09 15:06:44 -0700 |
commit | bbeecaa06049a7e9a063a754c8a58765a692f521 (patch) | |
tree | 07c40c863c3ee4a4d481c102327e204acf8f7cc0 /lib/unicorn/configurator.rb | |
parent | 9dd3c170e92f1e7559ee329bbde34ea4b17b715c (diff) | |
download | unicorn-bbeecaa06049a7e9a063a754c8a58765a692f521.tar.gz |
It has come to our attention that this setting is not very well-known to the rest of the world...
Diffstat (limited to 'lib/unicorn/configurator.rb')
-rw-r--r-- | lib/unicorn/configurator.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/unicorn/configurator.rb b/lib/unicorn/configurator.rb index 77a55ad..c7afece 100644 --- a/lib/unicorn/configurator.rb +++ b/lib/unicorn/configurator.rb @@ -175,6 +175,23 @@ module Unicorn # to the scheduling limitations by the worker process. Due the # low-complexity, low-overhead implementation, timeouts of less # than 3.0 seconds can be considered inaccurate and unsafe. + # + # For running Unicorn behind nginx, it is recommended to set + # "fail_timeout=0" for in your nginx configuration like this + # to have nginx always retry backends that may have had workers + # SIGKILL-ed due to timeouts. + # + # # See http://wiki.nginx.org/NginxHttpUpstreamModule for more details + # # on nginx upstream configuration: + # upstream unicorn_backend { + # # for UNIX domain socket setups: + # server unix:/path/to/unicorn.sock fail_timeout=0; + # + # # for TCP setups + # server 192.168.0.7:8080 fail_timeout=0; + # server 192.168.0.8:8080 fail_timeout=0; + # server 192.168.0.9:8080 fail_timeout=0; + # } def timeout(seconds) Numeric === seconds or raise ArgumentError, "not numeric: timeout=#{seconds.inspect}" |