Skip to content

Commit

Permalink
tweak fpm config
Browse files Browse the repository at this point in the history
  • Loading branch information
juliangut committed May 21, 2024
1 parent f5bb707 commit 5dbe645
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
6 changes: 6 additions & 0 deletions templates/fpm/php-fpm-www.conf.twig
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ group = docker
; Note: This value is mandatory.
listen = [::]:9000

; The number of requests each child process should execute before respawning.
; This can be useful to work around memory leaks in 3rd party libraries. For
; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS.
; Default Value: 0
pm.max_requests = 500

; Clear environment in FPM workers
; Prevents arbitrary environment variables from reaching FPM worker processes
; by clearing the environment in workers before env vars specified in this
Expand Down
21 changes: 21 additions & 0 deletions templates/fpm/php-fpm.conf.twig
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,25 @@ error_log = /var/log/php/php-fpm.log
; Default Value: notice
log_level = notice

; If this number of child processes exit with SIGSEGV or SIGBUS within the time
; interval set by emergency_restart_interval then FPM will restart. A value
; of '0' means 'Off'.
; Default Value: 0
emergency_restart_threshold = 10

; Interval of time used by emergency_restart_interval to determine when
; a graceful restart will be initiated. This can be useful to work around
; accidental corruptions in an accelerator's shared memory.
; Available Units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
emergency_restart_interval = 1m

; Time limit for child processes to wait for a reaction on signals from master.
; Available units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
process_control_timeout = 10s


{{ comment }}

0 comments on commit 5dbe645

Please sign in to comment.