wok-current diff php56-fpm/stuff/www.conf @ rev 25786
Bump gvfs to fix issue with open files on android device, patch udev to fix mtp issue on pcmanfm
| author | Stanislas Leduc <shann@slitaz.org> |
|---|---|
| date | Tue Jul 29 18:05:13 2025 +0000 (2 months ago) |
| parents | |
| children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/php56-fpm/stuff/www.conf Tue Jul 29 18:05:13 2025 +0000 1.3 @@ -0,0 +1,490 @@ 1.4 +; Start a new pool named 'www'. 1.5 +; the variable $pool can be used in any directive and will be replaced by the 1.6 +; pool name ('www' here) 1.7 +[www] 1.8 + 1.9 +; Per pool prefix 1.10 +; It only applies on the following directives: 1.11 +; - 'access.log' 1.12 +; - 'slowlog' 1.13 +; - 'listen' (unixsocket) 1.14 +; - 'chroot' 1.15 +; - 'chdir' 1.16 +; - 'php_values' 1.17 +; - 'php_admin_values' 1.18 +; When not set, the global prefix (or /usr) applies instead. 1.19 +; Note: This directive can also be relative to the global prefix. 1.20 +; Default Value: none 1.21 +;prefix = /path/to/pools/$pool 1.22 + 1.23 +; Unix user/group of the child processes. This can be used only if the master 1.24 +; process running user is root. It is set after the child process is created. 1.25 +; The user and group can be specified either by their name or by their numeric 1.26 +; IDs. 1.27 +; Note: If the user is root, the executable needs to be started with 1.28 +; --allow-to-run-as-root option to work. 1.29 +; Default Values: The user is set to master process running user by default. 1.30 +; If the group is not set, the user's group is used. 1.31 +user = www 1.32 +group = www 1.33 + 1.34 +; The address on which to accept FastCGI requests. 1.35 +; Valid syntaxes are: 1.36 +; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on 1.37 +; a specific port; 1.38 +; '[ip:6:addr:ess]:port' - to listen on a TCP socket to a specific IPv6 address on 1.39 +; a specific port; 1.40 +; 'port' - to listen on a TCP socket to all addresses 1.41 +; (IPv6 and IPv4-mapped) on a specific port; 1.42 +; '/path/to/unix/socket' - to listen on a unix socket. 1.43 +; Note: This value is mandatory. 1.44 +listen = /var/run/php/php5.6-fpm.sock 1.45 + 1.46 +; Set listen(2) backlog. 1.47 +; Default Value: 511 (-1 on Linux, FreeBSD and OpenBSD) 1.48 +;listen.backlog = 511 1.49 + 1.50 +; Set permissions for unix socket, if one is used. In Linux, read/write 1.51 +; permissions must be set in order to allow connections from a web server. Many 1.52 +; BSD-derived systems allow connections regardless of permissions. The owner 1.53 +; and group can be specified either by name or by their numeric IDs. 1.54 +; Default Values: Owner is set to the master process running user. If the group 1.55 +; is not set, the owner's group is used. Mode is set to 0660. 1.56 +listen.owner = www 1.57 +listen.group = www 1.58 +;listen.mode = 0660 1.59 + 1.60 +; When POSIX Access Control Lists are supported you can set them using 1.61 +; these options, value is a comma separated list of user/group names. 1.62 +; When set, listen.owner and listen.group are ignored 1.63 +;listen.acl_users = 1.64 +;listen.acl_groups = 1.65 + 1.66 +; List of addresses (IPv4/IPv6) of FastCGI clients which are allowed to connect. 1.67 +; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original 1.68 +; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address 1.69 +; must be separated by a comma. If this value is left blank, connections will be 1.70 +; accepted from any ip address. 1.71 +; Default Value: any 1.72 +;listen.allowed_clients = 127.0.0.1 1.73 + 1.74 +; Set the associated the route table (FIB). FreeBSD only 1.75 +; Default Value: -1 1.76 +;listen.setfib = 1 1.77 + 1.78 +; Specify the nice(2) priority to apply to the pool processes (only if set) 1.79 +; The value can vary from -19 (highest priority) to 20 (lower priority) 1.80 +; Note: - It will only work if the FPM master process is launched as root 1.81 +; - The pool processes will inherit the master process priority 1.82 +; unless it specified otherwise 1.83 +; Default Value: no set 1.84 +; process.priority = -19 1.85 + 1.86 +; Set the process dumpable flag (PR_SET_DUMPABLE prctl for Linux or 1.87 +; PROC_TRACE_CTL procctl for FreeBSD) even if the process user 1.88 +; or group is different than the master process user. It allows to create process 1.89 +; core dump and ptrace the process for the pool user. 1.90 +; Default Value: no 1.91 +; process.dumpable = yes 1.92 + 1.93 +; Choose how the process manager will control the number of child processes. 1.94 +; Possible Values: 1.95 +; static - a fixed number (pm.max_children) of child processes; 1.96 +; dynamic - the number of child processes are set dynamically based on the 1.97 +; following directives. With this process management, there will be 1.98 +; always at least 1 children. 1.99 +; pm.max_children - the maximum number of children that can 1.100 +; be alive at the same time. 1.101 +; pm.start_servers - the number of children created on startup. 1.102 +; pm.min_spare_servers - the minimum number of children in 'idle' 1.103 +; state (waiting to process). If the number 1.104 +; of 'idle' processes is less than this 1.105 +; number then some children will be created. 1.106 +; pm.max_spare_servers - the maximum number of children in 'idle' 1.107 +; state (waiting to process). If the number 1.108 +; of 'idle' processes is greater than this 1.109 +; number then some children will be killed. 1.110 +; pm.max_spawn_rate - the maximum number of rate to spawn child 1.111 +; processes at once. 1.112 +; ondemand - no children are created at startup. Children will be forked when 1.113 +; new requests will connect. The following parameter are used: 1.114 +; pm.max_children - the maximum number of children that 1.115 +; can be alive at the same time. 1.116 +; pm.process_idle_timeout - The number of seconds after which 1.117 +; an idle process will be killed. 1.118 +; Note: This value is mandatory. 1.119 +pm = dynamic 1.120 + 1.121 +; The number of child processes to be created when pm is set to 'static' and the 1.122 +; maximum number of child processes when pm is set to 'dynamic' or 'ondemand'. 1.123 +; This value sets the limit on the number of simultaneous requests that will be 1.124 +; served. Equivalent to the ApacheMaxClients directive with mpm_prefork. 1.125 +; Equivalent to the PHP_FCGI_CHILDREN environment variable in the original PHP 1.126 +; CGI. The below defaults are based on a server without much resources. Don't 1.127 +; forget to tweak pm.* to fit your needs. 1.128 +; Note: Used when pm is set to 'static', 'dynamic' or 'ondemand' 1.129 +; Note: This value is mandatory. 1.130 +pm.max_children = 5 1.131 + 1.132 +; The number of child processes created on startup. 1.133 +; Note: Used only when pm is set to 'dynamic' 1.134 +; Default Value: (min_spare_servers + max_spare_servers) / 2 1.135 +pm.start_servers = 2 1.136 + 1.137 +; The desired minimum number of idle server processes. 1.138 +; Note: Used only when pm is set to 'dynamic' 1.139 +; Note: Mandatory when pm is set to 'dynamic' 1.140 +pm.min_spare_servers = 1 1.141 + 1.142 +; The desired maximum number of idle server processes. 1.143 +; Note: Used only when pm is set to 'dynamic' 1.144 +; Note: Mandatory when pm is set to 'dynamic' 1.145 +pm.max_spare_servers = 3 1.146 + 1.147 +; The number of rate to spawn child processes at once. 1.148 +; Note: Used only when pm is set to 'dynamic' 1.149 +; Note: Mandatory when pm is set to 'dynamic' 1.150 +; Default Value: 32 1.151 +;pm.max_spawn_rate = 32 1.152 + 1.153 +; The number of seconds after which an idle process will be killed. 1.154 +; Note: Used only when pm is set to 'ondemand' 1.155 +; Default Value: 10s 1.156 +;pm.process_idle_timeout = 10s; 1.157 + 1.158 +; The number of requests each child process should execute before respawning. 1.159 +; This can be useful to work around memory leaks in 3rd party libraries. For 1.160 +; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS. 1.161 +; Default Value: 0 1.162 +;pm.max_requests = 500 1.163 + 1.164 +; The URI to view the FPM status page. If this value is not set, no URI will be 1.165 +; recognized as a status page. It shows the following information: 1.166 +; pool - the name of the pool; 1.167 +; process manager - static, dynamic or ondemand; 1.168 +; start time - the date and time FPM has started; 1.169 +; start since - number of seconds since FPM has started; 1.170 +; accepted conn - the number of request accepted by the pool; 1.171 +; listen queue - the number of request in the queue of pending 1.172 +; connections (see backlog in listen(2)); 1.173 +; max listen queue - the maximum number of requests in the queue 1.174 +; of pending connections since FPM has started; 1.175 +; listen queue len - the size of the socket queue of pending connections; 1.176 +; idle processes - the number of idle processes; 1.177 +; active processes - the number of active processes; 1.178 +; total processes - the number of idle + active processes; 1.179 +; max active processes - the maximum number of active processes since FPM 1.180 +; has started; 1.181 +; max children reached - number of times, the process limit has been reached, 1.182 +; when pm tries to start more children (works only for 1.183 +; pm 'dynamic' and 'ondemand'); 1.184 +; Value are updated in real time. 1.185 +; Example output: 1.186 +; pool: www 1.187 +; process manager: static 1.188 +; start time: 01/Jul/2011:17:53:49 +0200 1.189 +; start since: 62636 1.190 +; accepted conn: 190460 1.191 +; listen queue: 0 1.192 +; max listen queue: 1 1.193 +; listen queue len: 42 1.194 +; idle processes: 4 1.195 +; active processes: 11 1.196 +; total processes: 15 1.197 +; max active processes: 12 1.198 +; max children reached: 0 1.199 +; 1.200 +; By default the status page output is formatted as text/plain. Passing either 1.201 +; 'html', 'xml' or 'json' in the query string will return the corresponding 1.202 +; output syntax. Example: 1.203 +; http://www.foo.bar/status 1.204 +; http://www.foo.bar/status?json 1.205 +; http://www.foo.bar/status?html 1.206 +; http://www.foo.bar/status?xml 1.207 +; 1.208 +; By default the status page only outputs short status. Passing 'full' in the 1.209 +; query string will also return status for each pool process. 1.210 +; Example: 1.211 +; http://www.foo.bar/status?full 1.212 +; http://www.foo.bar/status?json&full 1.213 +; http://www.foo.bar/status?html&full 1.214 +; http://www.foo.bar/status?xml&full 1.215 +; The Full status returns for each process: 1.216 +; pid - the PID of the process; 1.217 +; state - the state of the process (Idle, Running, ...); 1.218 +; start time - the date and time the process has started; 1.219 +; start since - the number of seconds since the process has started; 1.220 +; requests - the number of requests the process has served; 1.221 +; request duration - the duration in µs of the requests; 1.222 +; request method - the request method (GET, POST, ...); 1.223 +; request URI - the request URI with the query string; 1.224 +; content length - the content length of the request (only with POST); 1.225 +; user - the user (PHP_AUTH_USER) (or '-' if not set); 1.226 +; script - the main script called (or '-' if not set); 1.227 +; last request cpu - the %cpu the last request consumed 1.228 +; it's always 0 if the process is not in Idle state 1.229 +; because CPU calculation is done when the request 1.230 +; processing has terminated; 1.231 +; last request memory - the max amount of memory the last request consumed 1.232 +; it's always 0 if the process is not in Idle state 1.233 +; because memory calculation is done when the request 1.234 +; processing has terminated; 1.235 +; If the process is in Idle state, then informations are related to the 1.236 +; last request the process has served. Otherwise informations are related to 1.237 +; the current request being served. 1.238 +; Example output: 1.239 +; ************************ 1.240 +; pid: 31330 1.241 +; state: Running 1.242 +; start time: 01/Jul/2011:17:53:49 +0200 1.243 +; start since: 63087 1.244 +; requests: 12808 1.245 +; request duration: 1250261 1.246 +; request method: GET 1.247 +; request URI: /test_mem.php?N=10000 1.248 +; content length: 0 1.249 +; user: - 1.250 +; script: /home/fat/web/docs/php/test_mem.php 1.251 +; last request cpu: 0.00 1.252 +; last request memory: 0 1.253 +; 1.254 +; Note: There is a real-time FPM status monitoring sample web page available 1.255 +; It's available in: /usr/share/php/8.2/fpm/status.html 1.256 +; 1.257 +; Note: The value must start with a leading slash (/). The value can be 1.258 +; anything, but it may not be a good idea to use the .php extension or it 1.259 +; may conflict with a real PHP file. 1.260 +; Default Value: not set 1.261 +;pm.status_path = /status 1.262 + 1.263 +; The address on which to accept FastCGI status request. This creates a new 1.264 +; invisible pool that can handle requests independently. This is useful 1.265 +; if the main pool is busy with long running requests because it is still possible 1.266 +; to get the status before finishing the long running requests. 1.267 +; 1.268 +; Valid syntaxes are: 1.269 +; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on 1.270 +; a specific port; 1.271 +; '[ip:6:addr:ess]:port' - to listen on a TCP socket to a specific IPv6 address on 1.272 +; a specific port; 1.273 +; 'port' - to listen on a TCP socket to all addresses 1.274 +; (IPv6 and IPv4-mapped) on a specific port; 1.275 +; '/path/to/unix/socket' - to listen on a unix socket. 1.276 +; Default Value: value of the listen option 1.277 +;pm.status_listen = 127.0.0.1:9001 1.278 + 1.279 +; The ping URI to call the monitoring page of FPM. If this value is not set, no 1.280 +; URI will be recognized as a ping page. This could be used to test from outside 1.281 +; that FPM is alive and responding, or to 1.282 +; - create a graph of FPM availability (rrd or such); 1.283 +; - remove a server from a group if it is not responding (load balancing); 1.284 +; - trigger alerts for the operating team (24/7). 1.285 +; Note: The value must start with a leading slash (/). The value can be 1.286 +; anything, but it may not be a good idea to use the .php extension or it 1.287 +; may conflict with a real PHP file. 1.288 +; Default Value: not set 1.289 +;ping.path = /ping 1.290 + 1.291 +; This directive may be used to customize the response of a ping request. The 1.292 +; response is formatted as text/plain with a 200 response code. 1.293 +; Default Value: pong 1.294 +;ping.response = pong 1.295 + 1.296 +; The access log file 1.297 +; Default: not set 1.298 +;access.log = log/$pool.access.log 1.299 + 1.300 +; The access log format. 1.301 +; The following syntax is allowed 1.302 +; %%: the '%' character 1.303 +; %C: %CPU used by the request 1.304 +; it can accept the following format: 1.305 +; - %{user}C for user CPU only 1.306 +; - %{system}C for system CPU only 1.307 +; - %{total}C for user + system CPU (default) 1.308 +; %d: time taken to serve the request 1.309 +; it can accept the following format: 1.310 +; - %{seconds}d (default) 1.311 +; - %{milliseconds}d 1.312 +; - %{milli}d 1.313 +; - %{microseconds}d 1.314 +; - %{micro}d 1.315 +; %e: an environment variable (same as $_ENV or $_SERVER) 1.316 +; it must be associated with embraces to specify the name of the env 1.317 +; variable. Some examples: 1.318 +; - server specifics like: %{REQUEST_METHOD}e or %{SERVER_PROTOCOL}e 1.319 +; - HTTP headers like: %{HTTP_HOST}e or %{HTTP_USER_AGENT}e 1.320 +; %f: script filename 1.321 +; %l: content-length of the request (for POST request only) 1.322 +; %m: request method 1.323 +; %M: peak of memory allocated by PHP 1.324 +; it can accept the following format: 1.325 +; - %{bytes}M (default) 1.326 +; - %{kilobytes}M 1.327 +; - %{kilo}M 1.328 +; - %{megabytes}M 1.329 +; - %{mega}M 1.330 +; %n: pool name 1.331 +; %o: output header 1.332 +; it must be associated with embraces to specify the name of the header: 1.333 +; - %{Content-Type}o 1.334 +; - %{X-Powered-By}o 1.335 +; - %{Transfert-Encoding}o 1.336 +; - .... 1.337 +; %p: PID of the child that serviced the request 1.338 +; %P: PID of the parent of the child that serviced the request 1.339 +; %q: the query string 1.340 +; %Q: the '?' character if query string exists 1.341 +; %r: the request URI (without the query string, see %q and %Q) 1.342 +; %R: remote IP address 1.343 +; %s: status (response code) 1.344 +; %t: server time the request was received 1.345 +; it can accept a strftime(3) format: 1.346 +; %d/%b/%Y:%H:%M:%S %z (default) 1.347 +; The strftime(3) format must be encapsulated in a %{<strftime_format>}t tag 1.348 +; e.g. for a ISO8601 formatted timestring, use: %{%Y-%m-%dT%H:%M:%S%z}t 1.349 +; %T: time the log has been written (the request has finished) 1.350 +; it can accept a strftime(3) format: 1.351 +; %d/%b/%Y:%H:%M:%S %z (default) 1.352 +; The strftime(3) format must be encapsulated in a %{<strftime_format>}t tag 1.353 +; e.g. for a ISO8601 formatted timestring, use: %{%Y-%m-%dT%H:%M:%S%z}t 1.354 +; %u: remote user 1.355 +; 1.356 +; Default: "%R - %u %t \"%m %r\" %s" 1.357 +;access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{milli}d %{kilo}M %C%%" 1.358 + 1.359 +; A list of request_uri values which should be filtered from the access log. 1.360 +; 1.361 +; As a security precuation, this setting will be ignored if: 1.362 +; - the request method is not GET or HEAD; or 1.363 +; - there is a request body; or 1.364 +; - there are query parameters; or 1.365 +; - the response code is outwith the successful range of 200 to 299 1.366 +; 1.367 +; Note: The paths are matched against the output of the access.format tag "%r". 1.368 +; On common configurations, this may look more like SCRIPT_NAME than the 1.369 +; expected pre-rewrite URI. 1.370 +; 1.371 +; Default Value: not set 1.372 +;access.suppress_path[] = /ping 1.373 +;access.suppress_path[] = /health_check.php 1.374 + 1.375 +; The log file for slow requests 1.376 +; Default Value: not set 1.377 +; Note: slowlog is mandatory if request_slowlog_timeout is set 1.378 +;slowlog = log/$pool.log.slow 1.379 + 1.380 +; The timeout for serving a single request after which a PHP backtrace will be 1.381 +; dumped to the 'slowlog' file. A value of '0s' means 'off'. 1.382 +; Available units: s(econds)(default), m(inutes), h(ours), or d(ays) 1.383 +; Default Value: 0 1.384 +;request_slowlog_timeout = 0 1.385 + 1.386 +; Depth of slow log stack trace. 1.387 +; Default Value: 20 1.388 +;request_slowlog_trace_depth = 20 1.389 + 1.390 +; The timeout for serving a single request after which the worker process will 1.391 +; be killed. This option should be used when the 'max_execution_time' ini option 1.392 +; does not stop script execution for some reason. A value of '0' means 'off'. 1.393 +; Available units: s(econds)(default), m(inutes), h(ours), or d(ays) 1.394 +; Default Value: 0 1.395 +;request_terminate_timeout = 0 1.396 + 1.397 +; The timeout set by 'request_terminate_timeout' ini option is not engaged after 1.398 +; application calls 'fastcgi_finish_request' or when application has finished and 1.399 +; shutdown functions are being called (registered via register_shutdown_function). 1.400 +; This option will enable timeout limit to be applied unconditionally 1.401 +; even in such cases. 1.402 +; Default Value: no 1.403 +;request_terminate_timeout_track_finished = no 1.404 + 1.405 +; Set open file descriptor rlimit. 1.406 +; Default Value: system defined value 1.407 +;rlimit_files = 1024 1.408 + 1.409 +; Set max core size rlimit. 1.410 +; Possible Values: 'unlimited' or an integer greater or equal to 0 1.411 +; Default Value: system defined value 1.412 +;rlimit_core = 0 1.413 + 1.414 +; Chroot to this directory at the start. This value must be defined as an 1.415 +; absolute path. When this value is not set, chroot is not used. 1.416 +; Note: you can prefix with '$prefix' to chroot to the pool prefix or one 1.417 +; of its subdirectories. If the pool prefix is not set, the global prefix 1.418 +; will be used instead. 1.419 +; Note: chrooting is a great security feature and should be used whenever 1.420 +; possible. However, all PHP paths will be relative to the chroot 1.421 +; (error_log, sessions.save_path, ...). 1.422 +; Default Value: not set 1.423 +;chroot = 1.424 + 1.425 +; Chdir to this directory at the start. 1.426 +; Note: relative path can be used. 1.427 +; Default Value: current directory or / when chroot 1.428 +;chdir = /var/www 1.429 + 1.430 +; Redirect worker stdout and stderr into main error log. If not set, stdout and 1.431 +; stderr will be redirected to /dev/null according to FastCGI specs. 1.432 +; Note: on highloaded environment, this can cause some delay in the page 1.433 +; process time (several ms). 1.434 +; Default Value: no 1.435 +;catch_workers_output = yes 1.436 + 1.437 +; Decorate worker output with prefix and suffix containing information about 1.438 +; the child that writes to the log and if stdout or stderr is used as well as 1.439 +; log level and time. This options is used only if catch_workers_output is yes. 1.440 +; Settings to "no" will output data as written to the stdout or stderr. 1.441 +; Default value: yes 1.442 +;decorate_workers_output = no 1.443 + 1.444 +; Clear environment in FPM workers 1.445 +; Prevents arbitrary environment variables from reaching FPM worker processes 1.446 +; by clearing the environment in workers before env vars specified in this 1.447 +; pool configuration are added. 1.448 +; Setting to "no" will make all environment variables available to PHP code 1.449 +; via getenv(), $_ENV and $_SERVER. 1.450 +; Default Value: yes 1.451 +;clear_env = no 1.452 + 1.453 +; Limits the extensions of the main script FPM will allow to parse. This can 1.454 +; prevent configuration mistakes on the web server side. You should only limit 1.455 +; FPM to .php extensions to prevent malicious users to use other extensions to 1.456 +; execute php code. 1.457 +; Note: set an empty value to allow all extensions. 1.458 +; Default Value: .php 1.459 +;security.limit_extensions = .php .php3 .php4 .php5 .php7 1.460 + 1.461 +; Pass environment variables like LD_LIBRARY_PATH. All $VARIABLEs are taken from 1.462 +; the current environment. 1.463 +; Default Value: clean env 1.464 +;env[HOSTNAME] = $HOSTNAME 1.465 +;env[PATH] = /usr/local/bin:/usr/bin:/bin 1.466 +;env[TMP] = /tmp 1.467 +;env[TMPDIR] = /tmp 1.468 +;env[TEMP] = /tmp 1.469 + 1.470 +; Additional php.ini defines, specific to this pool of workers. These settings 1.471 +; overwrite the values previously defined in the php.ini. The directives are the 1.472 +; same as the PHP SAPI: 1.473 +; php_value/php_flag - you can set classic ini defines which can 1.474 +; be overwritten from PHP call 'ini_set'. 1.475 +; php_admin_value/php_admin_flag - these directives won't be overwritten by 1.476 +; PHP call 'ini_set' 1.477 +; For php_*flag, valid values are on, off, 1, 0, true, false, yes or no. 1.478 + 1.479 +; Defining 'extension' will load the corresponding shared extension from 1.480 +; extension_dir. Defining 'disable_functions' or 'disable_classes' will not 1.481 +; overwrite previously defined php.ini values, but will append the new value 1.482 +; instead. 1.483 + 1.484 +; Note: path INI options can be relative and will be expanded with the prefix 1.485 +; (pool, global or /usr) 1.486 + 1.487 +; Default Value: nothing is defined by default except the values in php.ini and 1.488 +; specified at startup with the -d argument 1.489 +;php_admin_value[sendmail_path] = /usr/sbin/sendmail -t -i -f www@my.domain.com 1.490 +;php_flag[display_errors] = off 1.491 +;php_admin_value[error_log] = /var/log/fpm-php.www.log 1.492 +;php_admin_flag[log_errors] = on 1.493 +;php_admin_value[memory_limit] = 32M