]> git.openstreetmap.org Git - chef.git/commitdiff
Use string names and unix domain sockets for nominatim FPM pools
authorTom Hughes <tom@compton.nu>
Sun, 29 Nov 2020 12:05:51 +0000 (12:05 +0000)
committerTom Hughes <tom@compton.nu>
Sun, 29 Nov 2020 12:15:04 +0000 (12:15 +0000)
cookbooks/nominatim/attributes/default.rb
cookbooks/nominatim/recipes/default.rb
cookbooks/nominatim/templates/default/nginx.erb

index 4e74848cd7dde1967440c1750aad700caefa3cdf..bf87600ba22ce512356f596952eaf74bb106e185 100644 (file)
@@ -13,8 +13,7 @@ default[:nominatim][:ui_repository] = "https://github.com/osm-search/nominatim-u
 default[:nominatim][:ui_revision] = "master"
 
 default[:nominatim][:fpm_pools] = {
-  :www => {
-    :port => 8000,
+  "nominatim.openstreetmap.org" => {
     :pm => "dynamic",
     :max_children => 60,
     :prometheus_port => 9253
index 42989db718d1bf4dc33ea7ec2c22ff38c5d8d9a8..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]
index 88bd3c90993e2962fb7107325444d933222b115d..a44e9382c0bf69c9266f23bbe6c37aad707e64c3 100644 (file)
@@ -1,5 +1,5 @@
 upstream nominatim_service {
-  server 127.0.0.1:<%= @pools[:www][:port ]%>;
+  server unix:/run/php/nominatim.openstreetmap.org.sock;
 }
 
 map $uri $nominatim_script_name {