]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/nominatim/recipes/default.rb
Set load average limit for re-renders to number of CPU threads
[chef.git] / cookbooks / nominatim / recipes / default.rb
index fc6d2e9e3d5408d439392b26886ecef807eabe3b..b5496a6526b0f44dbc988db9476cdd8a533d91ea 100644 (file)
@@ -380,7 +380,7 @@ end
 end
 
 node[:nominatim][:fpm_pools].each do |name, data|
-  php_fpm name.to_s do
+  php_fpm name do
     port data[:port]
     pm data[:pm]
     pm_max_children data[:max_children]
@@ -388,6 +388,7 @@ node[:nominatim][:fpm_pools].each do |name, data|
     pm_min_spare_servers 10
     pm_max_spare_servers 20
     pm_max_requests 10000
+    prometheus_port data[:prometheus_port]
   end
 end
 
@@ -412,7 +413,7 @@ nginx_site "default" do
   action [:delete]
 end
 
-frontends = search(:node, "recipes:web\\:\\:frontend")
+frontends = search(:node, "recipes:web\\:\\:frontend").sort_by(&:name)
 
 nginx_site "nominatim" do
   template "nginx.erb"
@@ -463,5 +464,5 @@ fail2ban_jail "nominatim_limit_req" do
   logpath "#{node[:nominatim][:logdir]}/nominatim.openstreetmap.org-error.log"
   ports [80, 443]
   maxretry 5
-  ignoreips frontend_addresses.flatten
+  ignoreips frontend_addresses.flatten.sort
 end