X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/cb9f25913c9199b6daa6a9985ac109e4fd35dbf8..c2ead87b1ff929532f5ae3107ae9ce7a50ceed5f:/cookbooks/tilecache/templates/default/nginx_tile.conf.erb diff --git a/cookbooks/tilecache/templates/default/nginx_tile.conf.erb b/cookbooks/tilecache/templates/default/nginx_tile.conf.erb index 4c99dfb0e..7343e066d 100644 --- a/cookbooks/tilecache/templates/default/nginx_tile.conf.erb +++ b/cookbooks/tilecache/templates/default/nginx_tile.conf.erb @@ -7,10 +7,12 @@ upstream tile_cache_backend { # Balancer: round-robin <% @caches.each do |cache| -%> <% if cache[:hostname] != node[:hostname] -%> +<% if node[:tilecache][:tile_siblings].include? cache[:fqdn] -%> <% cache.ipaddresses(:family => :inet, :role => :external).sort.each do |address| -%> server <%= address %> backup; # Server <%= cache[:hostname] %> <% end -%> <% end -%> +<% end -%> <% end -%> keepalive 256; @@ -96,7 +98,7 @@ server { proxy_http_version 1.1; proxy_set_header Connection ''; - proxy_connect_timeout 10s; + proxy_connect_timeout 5s; # Preserve host header. proxy_set_header Host $host;