Skip to content

Instantly share code, notes, and snippets.

@zllovesuki
Created June 16, 2014 06:11
Show Gist options
  • Save zllovesuki/8489b4afac67ac2f8741 to your computer and use it in GitHub Desktop.
Save zllovesuki/8489b4afac67ac2f8741 to your computer and use it in GitHub Desktop.
/etc/php-fpm.d/website1.conf
[website1]
prefix = /home/dir
listen = var/fcgi/php.sock
listen.backlog = -1
listen.allowed_clients = 127.0.0.1
listen.mode = 0666
user = tony
group = tony
pm = dynamic
pm.max_children = 15
pm.start_servers = 5
pm.min_spare_servers = 5
pm.max_spare_servers = 15
pm.max_requests = 1000
request_slowlog_timeout = 60s
request_terminate_timeout = 300
chroot = $prefix
chdir = /
env[DOCUMENT_ROOT] = /web
slowlog = /var/log/$pool-slow.log
catch_workers_output = yes
php_flag[display_errors] = on
php_admin_value[error_log] = /var/log/$pool-error.log
php_admin_flag[log_errors] = on
php_admin_value[auto_prepend_file] = /bin/phpfix
php_admin_value[doc_root] = /web
php_admin_value[cgi.fix_pathinfo] = 0
; Change the following according to your needs
php_value[session.save_handler] = memcached
php_value[session.save_path] = "127.0.0.1:8000"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment