af9dc8
; Start a new pool named 'www'.
af9dc8
[www]
af9dc8
af9dc8
; The address on which to accept FastCGI requests.
af9dc8
; Valid syntaxes are:
af9dc8
;   'ip.add.re.ss:port'    - to listen on a TCP socket to a specific address on
af9dc8
;                            a specific port;
af9dc8
;   'port'                 - to listen on a TCP socket to all addresses on a
af9dc8
;                            specific port;
af9dc8
;   '/path/to/unix/socket' - to listen on a unix socket.
af9dc8
; Note: This value is mandatory.
af9dc8
listen = 127.0.0.1:9000
af9dc8
af9dc8
; Set listen(2) backlog. A value of '-1' means unlimited.
af9dc8
; Default Value: -1
af9dc8
;listen.backlog = -1
af9dc8
 
af9dc8
; List of ipv4 addresses of FastCGI clients which are allowed to connect.
af9dc8
; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original
af9dc8
; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address
af9dc8
; must be separated by a comma. If this value is left blank, connections will be
af9dc8
; accepted from any ip address.
af9dc8
; Default Value: any
af9dc8
listen.allowed_clients = 127.0.0.1
af9dc8
af9dc8
; Set permissions for unix socket, if one is used. In Linux, read/write
af9dc8
; permissions must be set in order to allow connections from a web server. Many
af9dc8
; BSD-derived systems allow connections regardless of permissions. 
af9dc8
; Default Values: user and group are set as the running user
af9dc8
;                 mode is set to 0666
af9dc8
;listen.owner = nobody
af9dc8
;listen.group = nobody
af9dc8
;listen.mode = 0666
af9dc8
af9dc8
; Unix user/group of processes
af9dc8
; Note: The user is mandatory. If the group is not set, the default user's group
af9dc8
;       will be used.
af9dc8
; RPM: apache Choosed to be able to access some dir as httpd
af9dc8
user = apache
af9dc8
; RPM: Keep a group allowed to write in log dir.
af9dc8
group = apache
af9dc8
af9dc8
; Choose how the process manager will control the number of child processes.
af9dc8
; Possible Values:
af9dc8
;   static  - a fixed number (pm.max_children) of child processes;
af9dc8
;   dynamic - the number of child processes are set dynamically based on the
af9dc8
;             following directives:
af9dc8
;             pm.max_children      - the maximum number of children that can
af9dc8
;                                    be alive at the same time.
af9dc8
;             pm.start_servers     - the number of children created on startup.
af9dc8
;             pm.min_spare_servers - the minimum number of children in 'idle'
af9dc8
;                                    state (waiting to process). If the number
af9dc8
;                                    of 'idle' processes is less than this
af9dc8
;                                    number then some children will be created.
af9dc8
;             pm.max_spare_servers - the maximum number of children in 'idle'
af9dc8
;                                    state (waiting to process). If the number
af9dc8
;                                    of 'idle' processes is greater than this
af9dc8
;                                    number then some children will be killed.
af9dc8
; Note: This value is mandatory.
af9dc8
pm = dynamic
af9dc8
af9dc8
; The number of child processes to be created when pm is set to 'static' and the
af9dc8
; maximum number of child processes to be created when pm is set to 'dynamic'.
af9dc8
; This value sets the limit on the number of simultaneous requests that will be
af9dc8
; served. Equivalent to the ApacheMaxClients directive with mpm_prefork.
af9dc8
; Equivalent to the PHP_FCGI_CHILDREN environment variable in the original PHP
af9dc8
; CGI.
af9dc8
; Note: Used when pm is set to either 'static' or 'dynamic'
af9dc8
; Note: This value is mandatory.
af9dc8
pm.max_children = 50
af9dc8
af9dc8
; The number of child processes created on startup.
af9dc8
; Note: Used only when pm is set to 'dynamic'
af9dc8
; Default Value: min_spare_servers + (max_spare_servers - min_spare_servers) / 2
af9dc8
pm.start_servers = 5
af9dc8
af9dc8
; The desired minimum number of idle server processes.
af9dc8
; Note: Used only when pm is set to 'dynamic'
af9dc8
; Note: Mandatory when pm is set to 'dynamic'
af9dc8
pm.min_spare_servers = 5
af9dc8
af9dc8
; The desired maximum number of idle server processes.
af9dc8
; Note: Used only when pm is set to 'dynamic'
af9dc8
; Note: Mandatory when pm is set to 'dynamic'
af9dc8
pm.max_spare_servers = 35
af9dc8
 
af9dc8
; The number of requests each child process should execute before respawning.
af9dc8
; This can be useful to work around memory leaks in 3rd party libraries. For
af9dc8
; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS.
af9dc8
; Default Value: 0
af9dc8
;pm.max_requests = 500
af9dc8
af9dc8
; The URI to view the FPM status page. If this value is not set, no URI will be
af9dc8
; recognized as a status page. By default, the status page shows the following
af9dc8
; information:
af9dc8
;   accepted conn    - the number of request accepted by the pool;
af9dc8
;   pool             - the name of the pool;
af9dc8
;   process manager  - static or dynamic;
af9dc8
;   idle processes   - the number of idle processes;
af9dc8
;   active processes - the number of active processes;
af9dc8
;   total processes  - the number of idle + active processes.
af9dc8
; The values of 'idle processes', 'active processes' and 'total processes' are
af9dc8
; updated each second. The value of 'accepted conn' is updated in real time.
af9dc8
; Example output:
af9dc8
;   accepted conn:   12073
af9dc8
;   pool:             www
af9dc8
;   process manager:  static
af9dc8
;   idle processes:   35
af9dc8
;   active processes: 65
af9dc8
;   total processes:  100
af9dc8
; By default the status page output is formatted as text/plain. Passing either
af9dc8
; 'html' or 'json' as a query string will return the corresponding output
af9dc8
; syntax. Example:
af9dc8
;   http://www.foo.bar/status
af9dc8
;   http://www.foo.bar/status?json
af9dc8
;   http://www.foo.bar/status?html
af9dc8
; Note: The value must start with a leading slash (/). The value can be
af9dc8
;       anything, but it may not be a good idea to use the .php extension or it
af9dc8
;       may conflict with a real PHP file.
af9dc8
; Default Value: not set 
af9dc8
;pm.status_path = /status
af9dc8
 
af9dc8
; The ping URI to call the monitoring page of FPM. If this value is not set, no
af9dc8
; URI will be recognized as a ping page. This could be used to test from outside
af9dc8
; that FPM is alive and responding, or to
af9dc8
; - create a graph of FPM availability (rrd or such);
af9dc8
; - remove a server from a group if it is not responding (load balancing);
af9dc8
; - trigger alerts for the operating team (24/7).
af9dc8
; Note: The value must start with a leading slash (/). The value can be
af9dc8
;       anything, but it may not be a good idea to use the .php extension or it
af9dc8
;       may conflict with a real PHP file.
af9dc8
; Default Value: not set
af9dc8
;ping.path = /ping
af9dc8
af9dc8
; This directive may be used to customize the response of a ping request. The
af9dc8
; response is formatted as text/plain with a 200 response code.
af9dc8
; Default Value: pong
af9dc8
;ping.response = pong
af9dc8
 
af9dc8
; The timeout for serving a single request after which the worker process will
af9dc8
; be killed. This option should be used when the 'max_execution_time' ini option
af9dc8
; does not stop script execution for some reason. A value of '0' means 'off'.
af9dc8
; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
af9dc8
; Default Value: 0
af9dc8
;request_terminate_timeout = 0
af9dc8
 
af9dc8
; The timeout for serving a single request after which a PHP backtrace will be
af9dc8
; dumped to the 'slowlog' file. A value of '0s' means 'off'.
af9dc8
; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
af9dc8
; Default Value: 0
af9dc8
;request_slowlog_timeout = 0
af9dc8
 
af9dc8
; The log file for slow requests
af9dc8
; Default Value: not set
af9dc8
; Note: slowlog is mandatory if request_slowlog_timeout is set
af9dc8
slowlog = /var/log/php-fpm/www-slow.log
af9dc8
 
af9dc8
; Set open file descriptor rlimit.
af9dc8
; Default Value: system defined value
af9dc8
;rlimit_files = 1024
af9dc8
 
af9dc8
; Set max core size rlimit.
af9dc8
; Possible Values: 'unlimited' or an integer greater or equal to 0
af9dc8
; Default Value: system defined value
af9dc8
;rlimit_core = 0
af9dc8
 
af9dc8
; Chroot to this directory at the start. This value must be defined as an
af9dc8
; absolute path. When this value is not set, chroot is not used.
af9dc8
; Note: chrooting is a great security feature and should be used whenever 
af9dc8
;       possible. However, all PHP paths will be relative to the chroot
af9dc8
;       (error_log, sessions.save_path, ...).
af9dc8
; Default Value: not set
af9dc8
;chroot = 
af9dc8
 
af9dc8
; Chdir to this directory at the start. This value must be an absolute path.
af9dc8
; Default Value: current directory or / when chroot
af9dc8
;chdir = /var/www
af9dc8
 
af9dc8
; Redirect worker stdout and stderr into main error log. If not set, stdout and
af9dc8
; stderr will be redirected to /dev/null according to FastCGI specs.
af9dc8
; Default Value: no
af9dc8
;catch_workers_output = yes
af9dc8
 
af9dc8
; Limits the extensions of the main script FPM will allow to parse. This can
af9dc8
; prevent configuration mistakes on the web server side. You should only limit
af9dc8
; FPM to .php extensions to prevent malicious users to use other extensions to
af9dc8
; exectute php code.
af9dc8
; Note: set an empty value to allow all extensions.
af9dc8
; Default Value: .php
af9dc8
;security.limit_extensions = .php .php3 .php4 .php5
af9dc8
af9dc8
; Pass environment variables like LD_LIBRARY_PATH. All $VARIABLEs are taken from
af9dc8
; the current environment.
af9dc8
; Default Value: clean env
af9dc8
;env[HOSTNAME] = $HOSTNAME
af9dc8
;env[PATH] = /usr/local/bin:/usr/bin:/bin
af9dc8
;env[TMP] = /tmp
af9dc8
;env[TMPDIR] = /tmp
af9dc8
;env[TEMP] = /tmp
af9dc8
af9dc8
; Additional php.ini defines, specific to this pool of workers. These settings
af9dc8
; overwrite the values previously defined in the php.ini. The directives are the
af9dc8
; same as the PHP SAPI:
af9dc8
;   php_value/php_flag             - you can set classic ini defines which can
af9dc8
;                                    be overwritten from PHP call 'ini_set'. 
af9dc8
;   php_admin_value/php_admin_flag - these directives won't be overwritten by
af9dc8
;                                     PHP call 'ini_set'
af9dc8
; For php_*flag, valid values are on, off, 1, 0, true, false, yes or no.
af9dc8
af9dc8
; Defining 'extension' will load the corresponding shared extension from
af9dc8
; extension_dir. Defining 'disable_functions' or 'disable_classes' will not
af9dc8
; overwrite previously defined php.ini values, but will append the new value
af9dc8
; instead.
af9dc8
af9dc8
; Default Value: nothing is defined by default except the values in php.ini and
af9dc8
;                specified at startup with the -d argument
af9dc8
;php_admin_value[sendmail_path] = /usr/sbin/sendmail -t -i -f www@my.domain.com
af9dc8
;php_flag[display_errors] = off
af9dc8
php_admin_value[error_log] = /var/log/php-fpm/www-error.log
af9dc8
php_admin_flag[log_errors] = on
af9dc8
;php_admin_value[memory_limit] = 128M
af9dc8
af9dc8
; Set session path to a directory owned by process user
af9dc8
php_value[session.save_handler] = files
af9dc8
php_value[session.save_path] = /var/lib/php/session
af9dc8