X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/2bfb0ef07fb64314f5c4ded641a8c280df9c1d0b..9b5a2c1032d93d7aac7eac09c542e084a6792961:/cookbooks/php/resources/fpm.rb diff --git a/cookbooks/php/resources/fpm.rb b/cookbooks/php/resources/fpm.rb index 657f3b51b..13c973580 100644 --- a/cookbooks/php/resources/fpm.rb +++ b/cookbooks/php/resources/fpm.rb @@ -53,9 +53,12 @@ action :create do if new_resource.prometheus_port prometheus_exporter "phpfpm" do port new_resource.prometheus_port + restrict_address_families "AF_UNIX" service service_name + group "www-data" command "server" - options "--phpfpm.scrape-uri=#{scrape_uri}" + options "--phpfpm.scrape-uri=#{scrape_uri} --phpfpm.fix-process-count" + labels "pool" => new_resource.pool end else prometheus_exporter "phpfpm" do @@ -93,7 +96,7 @@ action_class do if new_resource.port "tcp://127.0.0.1:#{new_resource.port}/status" else - "unix:///run/php/#{new_resource.pool}.sock;/status" + "unix:///run/php/php-#{new_resource.pool}-fpm.sock;/status" end end end