-
Notifications
You must be signed in to change notification settings - Fork 11
/
php-fpm-www.conf
47 lines (37 loc) · 1.26 KB
/
php-fpm-www.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
[global]
daemonize = no
; stdout and stderr (/proc/self/fd/2) is routed to /proc/1/fd/2 via supervisord, as in process logs are output to docker output
error_log = /dev/stderr
log_level = notice
[www]
user = www
group = www
; Ignore these settings - dodgy php-fpm error handling is worked around
; with the error_log directive below
; access.log = /dev/stderr
; access.format = "%R %u %s \"%m %r\""
; Turning this on results in a double up of error logs, once for the worker, and secondarily for php-fpm. Instead we skip both and go straight to /proc/1/fd/2 via error_log set below.
catch_workers_output = no
clear_env = no
listen = /run/php-fpm.sock
listen.owner = www
listen.group = www
listen.mode = 0660
pm = ondemand
pm.process_idle_timeout = 10s
pm.max_requests = 1000
; Edited by /auto-fpm.sh
pm.max_children = 5
pm.max_spare_servers = 30
; Admin settings can't be overridden
php_admin_flag[log_errors] = on
php_admin_value[log_errors_max_len] = 4096
php_admin_value[error_log] = /proc/1/fd/2
; Normals can be
php_flag[display_errors] = off
php_value[date.timezone] = UTC
; this should match FPM_PROCESS_MEMORY_MB in /auto-fpm.sh
php_value[memory_limit] = 128M
php_value[upload_max_filesize] = 512M
php_value[post_max_size] = 20M
php_value[default_socket_timeout] = 300