├── .gitignore ├── cron.sh ├── Makefile ├── config ├── nginx │ ├── map_https_fcgi.conf │ ├── fastcgi.conf │ ├── map_block_http_methods.conf │ ├── php_fpm_status_allowed_hosts.conf │ ├── nginx_status_allowed_hosts.conf │ ├── cron_allowed_hosts.conf │ ├── default │ ├── blacklist.conf │ ├── drupal_upload_progress.conf │ ├── upstream_phpcgi_unix.conf │ ├── fastcgi_microcache_zone.conf │ ├── map_cache.conf │ ├── fastcgi_drupal.conf │ ├── fastcgi_no_args_drupal.conf │ ├── microcache_fcgi_auth.conf │ ├── microcache_fcgi.conf │ ├── drupal.conf │ ├── mime.types │ └── nginx.conf ├── supervisor │ └── supervisord-nginx.conf └── php │ ├── www.conf │ └── php.ini ├── mail.sh ├── startup.sh ├── README.md └── Dockerfile /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | -------------------------------------------------------------------------------- /cron.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | /opt/startup.sh 4 | /opt/mail.sh 5 | /usr/local/bin/drush cron 6 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | CURRENT_DIRECTORY := $(shell pwd) 2 | 3 | build: 4 | @docker build --tag=iiiepe/nginx-drupal $(CURRENT_DIRECTORY) 5 | 6 | build-no-cache: 7 | @docker build --no-cache --tag=iiiepe/nginx-drupal $(CURRENT_DIRECTORY) 8 | 9 | .PHONY: build 10 | 11 | -------------------------------------------------------------------------------- /config/nginx/map_https_fcgi.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: conf; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | ### Implement the $https_if_not_empty variable for Nginx versions below 1.1.11. 3 | 4 | map $scheme $https { 5 | default ''; 6 | https on; 7 | } 8 | -------------------------------------------------------------------------------- /config/nginx/fastcgi.conf: -------------------------------------------------------------------------------- 1 | #-*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | ### Generic fastcgi configuration. 3 | include fastcgi_params; 4 | fastcgi_buffers 256 4k; 5 | fastcgi_intercept_errors on; 6 | ## allow 4 hrs - pass timeout responsibility to upstream. 7 | fastcgi_read_timeout 14400; 8 | fastcgi_index index.php; -------------------------------------------------------------------------------- /config/nginx/map_block_http_methods.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | 3 | ### This file contains a map directive that is used to block the 4 | ### invocation of HTTP methods. Out of the box it allows for HEAD, GET and POST. 5 | 6 | map $request_method $not_allowed_method { 7 | default 1; 8 | GET 0; 9 | HEAD 0; 10 | POST 0; 11 | } 12 | -------------------------------------------------------------------------------- /config/nginx/php_fpm_status_allowed_hosts.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | ### Configuration of php-fpm status and ping pages. Here we define the 3 | ### allowed hosts using the Geo Module. http://wiki.nginx.org/HttpGeoModule 4 | 5 | geo $dont_show_fpm_status { 6 | default 1; 7 | 127.0.0.1 0; # allow on the loopback 8 | 192.168.1.0/24 0; # allow on an internal network 9 | } -------------------------------------------------------------------------------- /config/nginx/nginx_status_allowed_hosts.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | 3 | ### Configuration of nginx stub status page. Here we define the 4 | ### allowed hosts using the Geo Module. http://wiki.nginx.org/HttpGeoModule 5 | 6 | geo $dont_show_nginx_status { 7 | default 1; 8 | 127.0.0.1 0; # allow on the loopback 9 | 192.168.1.0/24 0; # allow on an internal network 10 | } 11 | -------------------------------------------------------------------------------- /config/nginx/cron_allowed_hosts.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode:autopair; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | ### Configuration file for specifying which hosts can invoke Drupal's 3 | ### cron. This only applies if you're not using drush to run cron. 4 | 5 | geo $not_allowed_cron { 6 | default 1; 7 | ## Add your set of hosts. 8 | 127.0.0.1 0; # allow the localhost 9 | 192.168.1.0/24 0; # allow on an internal network 10 | } 11 | -------------------------------------------------------------------------------- /mail.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | cat > /etc/msmtprc <.*)/x-progress-id:(?\d*) { 14 | rewrite ^ $upload_form_uri?X-Progress-ID=$upload_id; 15 | } 16 | 17 | ## Now the above rewrite must be matched by a location that 18 | ## activates it and references the above defined upload 19 | ## tracking zone. 20 | location ^~ /progress { 21 | upload_progress_json_output; 22 | report_uploads uploads; 23 | } 24 | -------------------------------------------------------------------------------- /config/nginx/upstream_phpcgi_unix.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | 3 | ### Upstream configuration for PHP FastCGI. 4 | 5 | ## Add as many servers as needed: 6 | ## Cf. http://wiki.nginx.org/HttpUpstreamModule. 7 | ## Note that this configuration assumes by default that keepalive 8 | ## upstream connections are supported and that you have a Nginx 9 | ## version with the fair load balancer. 10 | 11 | ## Add as many servers as needed. Cf. http://wiki.nginx.org/HttpUpstreamModule. 12 | upstream phpcgi { 13 | ## Use the least connection algorithm for load balancing. This 14 | ## algorithm was introduced in versions 1.3.1 and 1.2.2. 15 | least_conn; 16 | 17 | server unix:/var/run/php-fpm.sock; 18 | ## Create a backend connection cache. Note that this requires 19 | ## Nginx version greater or equal to 1.1.4. 20 | ## Cf. http://nginx.org/en/CHANGES. Comment out the following 21 | ## line if that's not the case. 22 | keepalive 5; 23 | } 24 | -------------------------------------------------------------------------------- /config/nginx/fastcgi_microcache_zone.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | 3 | ### Defining the FastCGI cache zone for the microcache as presented at: 4 | ## http://fennb.com/microcaching-speed-your-app-up-250x-with-no-n. 5 | 6 | ## If youre using a Nginx version greater than 1.1.1 then you can 7 | ## tweak the Tweaking of the cache loader parameters. 8 | ## Cf. http://forum.nginx.org/read.php?21,213197,213209#msg-213209 for 9 | ## rationale. If you're using a Nginx version lower than 1.1.1 then 10 | ## comment the line below and use the cache zone configuration below this one. 11 | fastcgi_cache_path /var/cache/nginx/microcache levels=1:2 keys_zone=microcache:5M max_size=1G inactive=2h loader_threshold=2592000000 loader_sleep=1 loader_files=100000; 12 | 13 | ## If you're not using a Nginx version greater or equal to 1.1.1 then 14 | ## comment the above configuration and use this one. No cache loader 15 | ## tweaking. 16 | #fastcgi_cache_path /var/cache/nginx/microcache levels=1:2 keys_zone=microcache:5M max_size=1G inactive=2h; 17 | -------------------------------------------------------------------------------- /config/nginx/map_cache.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-current-dictionary: american -*- 2 | 3 | ### Testing if we should be serving content from cache or not. This is 4 | ### needed for any Drupal setup that uses an external cache. 5 | 6 | ## Let Ajax calls go through. 7 | map $uri $no_cache_ajax { 8 | default 0; 9 | /system/ajax 1; 10 | } 11 | 12 | ## Testing for the session cookie being present. If there is then no 13 | ## caching is to be done. Note that this is for someone using either 14 | ## Drupal 7 pressflow or stock Drupal 6 core with no_anon 15 | ## (http://drupal.org/project/no_anon). 16 | map $http_cookie $no_cache_cookie { 17 | default 0; 18 | ~SESS 1; # PHP session cookie 19 | } 20 | 21 | ## Combine both results to get the cache bypassing mapping. 22 | map $no_cache_ajax$no_cache_cookie $no_cache { 23 | default 1; 24 | 00 0; 25 | } 26 | 27 | ## If you're using stock Drupal 6 without no_anon, i.e., there's a 28 | ## session cookie being served even to anonymous users, then uncomment 29 | ## the three lines below and comment the above map directive 30 | # map $http_cookie $no_cache { 31 | # default 0; 32 | # ~DRUPAL_UID 1; # DRUPAL_UID cookie set by Boost 33 | # } 34 | 35 | ## Set a cache_uid variable for authenticated users. 36 | map $http_cookie $cache_uid { 37 | default nil; # hommage to Lisp :) 38 | ~SESS[[:alnum:]]+=(?[[:graph:]]+) $session_id; 39 | } 40 | -------------------------------------------------------------------------------- /startup.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | ENV_CONF=/etc/php5/fpm/pool.d/env.conf 4 | 5 | echo "Configuring Nginx and PHP5-FPM with environment variables" 6 | 7 | # Update php5-fpm with access to Docker environment variables 8 | echo '[www]' > $ENV_CONF 9 | for var in $(env | awk -F= '{print $1}') 10 | do 11 | echo "Adding variable {$var}" 12 | echo "env[${var}] = ${!var}" >> $ENV_CONF 13 | done 14 | 15 | # We need to configure the /etc/hosts file so sendmail works properly 16 | # sendmail needs in this file something in the form of host.domain 17 | # this is actually really easy to do with docker itself, adding -h something.localdomain 18 | # when running the container, but it presents two problems: 19 | # first, it doesn't work with maestro-ng and many other solutions that don't support 20 | # the -h argument 21 | # second, there's no way to use the container's name, when using -h we need to define 22 | # the container's name so is not an ideal solution because other thinks can break 23 | # when setting the name manually 24 | # We then just rewrite the hosts file 25 | echo "Configuring /etc/hosts" 26 | 27 | CONTAINER_IP=$(/sbin/ifconfig eth0 | grep 'inet addr:' | cut -d: -f2 | awk '{ print $1}') 28 | CONTAINER_NAME=$(echo $HOSTNAME) 29 | 30 | echo $CONTAINER_IP " " $CONTAINER_NAME $CONTAINER_NAME".localdomain" > /etc/hosts 31 | echo "127.0.0.1 localhost" >> /etc/hosts 32 | echo "::1 localhost ip6-localhost ip6-loopback" >> /etc/hosts 33 | echo "fe00::0 ip6-localnet" >> /etc/hosts 34 | echo "ff00::0 ip6-mcastprefix" >> /etc/hosts 35 | echo "ff02::1 ip6-allnodes" >> /etc/hosts 36 | echo "ff02::2 ip6-allrouters" >> /etc/hosts -------------------------------------------------------------------------------- /config/nginx/fastcgi_drupal.conf: -------------------------------------------------------------------------------- 1 | ### fastcgi configuration for serving private files. 2 | ## 1. Parameters. 3 | fastcgi_param QUERY_STRING q=$uri&$args; 4 | fastcgi_param REQUEST_METHOD $request_method; 5 | fastcgi_param CONTENT_TYPE $content_type; 6 | fastcgi_param CONTENT_LENGTH $content_length; 7 | fastcgi_param SCRIPT_NAME /index.php; 8 | fastcgi_param REQUEST_URI $request_uri; 9 | fastcgi_param DOCUMENT_URI $document_uri; 10 | fastcgi_param DOCUMENT_ROOT $document_root; 11 | fastcgi_param SERVER_PROTOCOL $server_protocol; 12 | fastcgi_param GATEWAY_INTERFACE CGI/1.1; 13 | fastcgi_param SERVER_SOFTWARE nginx/$nginx_version; 14 | fastcgi_param REMOTE_ADDR $remote_addr; 15 | fastcgi_param REMOTE_PORT $remote_port; 16 | fastcgi_param SERVER_ADDR $server_addr; 17 | fastcgi_param SERVER_PORT $server_port; 18 | fastcgi_param SERVER_NAME $server_name; 19 | 20 | ## PHP only, required if PHP was built with --enable-force-cgi-redirect 21 | fastcgi_param REDIRECT_STATUS 200; 22 | fastcgi_param SCRIPT_FILENAME $document_root/index.php; 23 | 24 | ## HTTPS 'on' parameter. This requires Nginx version 1.1.11 or 25 | ## later. The if_not_empty flag was introduced in 1.1.11. See: 26 | ## http://nginx.org/en/CHANGES. If using a version that doesn't 27 | ## support this comment out the line below. 28 | fastcgi_param HTTPS $fastcgi_https if_not_empty; 29 | 30 | ## For Nginx versions below 1.1.11 uncomment the line below after commenting out the above. 31 | #fastcgi_param HTTPS $fastcgi_https; 32 | 33 | ## 2. Nginx FCGI specific directives. 34 | fastcgi_buffers 256 4k; 35 | fastcgi_intercept_errors on; 36 | 37 | ## Allow 4 hrs - pass timeout responsibility to upstream. 38 | fastcgi_read_timeout 14400; 39 | fastcgi_index index.php; 40 | 41 | ## Hide the X-Drupal-Cache header provided by Pressflow. 42 | fastcgi_hide_header 'X-Drupal-Cache'; 43 | 44 | ## Hide the Drupal 7 header X-Generator. 45 | fastcgi_hide_header 'X-Generator'; -------------------------------------------------------------------------------- /config/nginx/fastcgi_no_args_drupal.conf: -------------------------------------------------------------------------------- 1 | #-*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | ### fastcgi configuration for serving private files. 3 | ## 1. Parameters. 4 | fastcgi_param QUERY_STRING q=$uri; 5 | fastcgi_param REQUEST_METHOD $request_method; 6 | fastcgi_param CONTENT_TYPE $content_type; 7 | fastcgi_param CONTENT_LENGTH $content_length; 8 | 9 | fastcgi_param SCRIPT_NAME /index.php; 10 | fastcgi_param REQUEST_URI $request_uri; 11 | fastcgi_param DOCUMENT_URI $document_uri; 12 | fastcgi_param DOCUMENT_ROOT $document_root; 13 | fastcgi_param SERVER_PROTOCOL $server_protocol; 14 | 15 | fastcgi_param GATEWAY_INTERFACE CGI/1.1; 16 | fastcgi_param SERVER_SOFTWARE nginx/$nginx_version; 17 | 18 | fastcgi_param REMOTE_ADDR $remote_addr; 19 | fastcgi_param REMOTE_PORT $remote_port; 20 | fastcgi_param SERVER_ADDR $server_addr; 21 | fastcgi_param SERVER_PORT $server_port; 22 | fastcgi_param SERVER_NAME $server_name; 23 | ## PHP only, required if PHP was built with --enable-force-cgi-redirect 24 | fastcgi_param REDIRECT_STATUS 200; 25 | fastcgi_param SCRIPT_FILENAME $document_root/index.php; 26 | ## HTTPS 'on' parameter. This requires Nginx version 1.1.11 or 27 | ## later. The if_not_empty flag was introduced in 1.1.11. See: 28 | ## http://nginx.org/en/CHANGES. If using a version that doesn't 29 | ## support this comment out the line below. 30 | fastcgi_param HTTPS $fastcgi_https if_not_empty; 31 | ## For Nginx versions below 1.1.11 uncomment the line below after commenting out the above. 32 | #fastcgi_param HTTPS $fastcgi_https; 33 | 34 | ## 2. Nginx FCGI specific directives. 35 | fastcgi_buffers 256 4k; 36 | fastcgi_intercept_errors on; 37 | ## Allow 4 hrs - pass timeout responsibility to upstream. 38 | fastcgi_read_timeout 14400; 39 | fastcgi_index index.php; 40 | ## Hide the X-Drupal-Cache header provided by Pressflow. 41 | fastcgi_hide_header 'X-Drupal-Cache'; 42 | ## Hide the Drupal 7 header X-Generator. 43 | fastcgi_hide_header 'X-Generator'; 44 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Docker image with Nginx and PHP 5.5.9 optimized for Drupal 7 2 | This image is build using Ubuntu 14.04 with Nginx and PHP 5.5.9 and is optimized to run Drupal 7. 3 | It can run Drupal 6 but most likelly you'll have PHP errors depending on the modules you have installed. In that case is recommended to use the image iiiepe/nginx-drupal6 or iiiepe/apache-drupal6 4 | 5 | Includes: 6 | 7 | - nginx 8 | - php 9 | - composer 10 | - drush 11 | 12 | Important: 13 | 14 | - Logs are at /var/log/supervisor so you can map that directory 15 | - Application root directory is /var/www so make sure you map the application there 16 | - Nginx configuration was provided by https://github.com/perusio/drupal-with-nginx but it's modified 17 | 18 | ## To build 19 | 20 | $ make build 21 | 22 | or 23 | 24 | $ docker build -t yourname/nginx-drupal . 25 | 26 | 27 | ## To run 28 | Nginx will look for files in /var/www so you need to map your application to that directory. 29 | 30 | $ docker run -d -p 8000:80 -v application:/var/www yourname/nginx-drupal 31 | 32 | If you want to link the container to a MySQL/MariaDB contaier do: 33 | 34 | $ docker run -d -p 8000:80 -v application:/var/www my_mysql_container:mysql yourname/nginx-drupal 35 | 36 | The startup.sh script will add the environment variables with MYSQL_ to /etc/php5/fpm/pool.d/env.conf so PHP-FPM detects them. If you need to use them you can do: 37 | 38 | 39 | ## Fig 40 | 41 | mysql: 42 | image: mysql 43 | expose: 44 | - "3306" 45 | environment: 46 | MYSQL_ROOT_PASSWORD: 123 47 | web: 48 | image: iiiepe/nginx-drupal 49 | volumes: 50 | - application:/var/www 51 | - logs:/var/log/supervisor 52 | ports: 53 | - "80:80" 54 | links: 55 | - "mysql:mysql" 56 | 57 | ## Running Drush 58 | With Fig this is actually easier and is the recommended way since if you're running Docker without fig, you'll have to link all containers before you run drush. 59 | 60 | $ fig run --rm web drush 61 | 62 | ### License 63 | Released under the MIT License. -------------------------------------------------------------------------------- /config/nginx/microcache_fcgi_auth.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | 3 | ### Implementation of the microcache concept as presented here: 4 | ### http://fennb.com/microcaching-speed-your-app-up-250x-with-no-n 5 | 6 | ## The cache zone referenced. 7 | fastcgi_cache microcache; 8 | 9 | ## The cache key. 10 | fastcgi_cache_key $cache_uid@$scheme$host$request_uri; 11 | 12 | ## For 200 and 301 make the cache valid for 15s. 13 | fastcgi_cache_valid 200 301 15s; 14 | 15 | ## For 302 make it valid for 1 minute. 16 | fastcgi_cache_valid 302 1m; 17 | 18 | ## For 404 make it valid 1 second. 19 | fastcgi_cache_valid 404 1s; 20 | 21 | ## If there are any upstream errors use whatever it is available. 22 | fastcgi_cache_use_stale error timeout invalid_header updating http_500; 23 | 24 | ## The Cache-Control and Expires headers should be delivered untouched 25 | ## from the upstream to the client. 26 | fastcgi_ignore_headers Cache-Control Expires; 27 | fastcgi_pass_header Set-Cookie; 28 | fastcgi_pass_header Cookie; 29 | 30 | ## Bypass the cache. 31 | # fastcgi_cache_bypass $no_auth_cache; 32 | # fastcgi_no_cache $no_auth_cache; 33 | 34 | ## Add a cache miss/hit status header. 35 | add_header X-Micro-Cache $upstream_cache_status; 36 | 37 | ## To avoid any interaction with the cache control headers we expire 38 | ## everything on this location immediately. 39 | expires epoch; 40 | 41 | ## Enable clickjacking protection in modern browsers. Available in 42 | ## IE8 also. See 43 | ## https://developer.mozilla.org/en/The_X-FRAME-OPTIONS_response_header 44 | ## This may conflicts with pseudo streaming (at least with Nginx version 1.0.12). 45 | ## Uncomment the line below if you're not using media streaming. 46 | ## For sites *not* using frames uncomment the line below. 47 | #add_header X-Frame-Options DENY; 48 | 49 | ## For sites *using* frames uncomment the line below. 50 | #add_header X-Frame-Options SAMEORIGIN; 51 | 52 | ## Block MIME type sniffing on IE. 53 | add_header X-Content-Options nosniff; 54 | 55 | ## If you're using a Nginx version greater than 1.1.11 then uncomment 56 | ## the line below. See: 57 | ## http://nginx.org/en/docs/http/ngx_http_fastcgi_module.html#fastcgi_cache_lock 58 | ## Cache locking mechanism for protecting the backend of too many 59 | ## simultaneous requests. 60 | fastcgi_cache_lock on; 61 | 62 | ## The default timeout, i.e., the time to way before forwarding the 63 | ## second request upstream if no reply as arrived in the meantime is 5s. 64 | fastcgi_cache_lock_timeout 8000; # in miliseconds. 65 | -------------------------------------------------------------------------------- /config/nginx/microcache_fcgi.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | 3 | ### Implementation of the microcache concept as presented here: 4 | ### http://fennb.com/microcaching-speed-your-app-up-250x-with-no-n 5 | 6 | ## The cache zone referenced. 7 | fastcgi_cache microcache; 8 | ## The cache key. 9 | fastcgi_cache_key $scheme$request_method$host$request_uri; 10 | 11 | ## For 200 and 301 make the cache valid for 1s seconds. 12 | fastcgi_cache_valid 200 301 1s; 13 | ## For 302 make it valid for 1 minute. 14 | fastcgi_cache_valid 302 1m; 15 | ## For 404 make it valid 1 second. 16 | fastcgi_cache_valid 404 1s; 17 | ## If there are any upstream errors or the item has expired use 18 | ## whatever it is available. 19 | fastcgi_cache_use_stale error timeout invalid_header updating http_500; 20 | ## The Cache-Control and Expires headers should be delivered untouched 21 | ## from the upstream to the client. 22 | fastcgi_ignore_headers Cache-Control Expires; 23 | ## Bypass the cache. 24 | fastcgi_cache_bypass $no_cache; 25 | fastcgi_no_cache $no_cache; 26 | ## Add a cache miss/hit status header. 27 | add_header X-Micro-Cache $upstream_cache_status; 28 | ## To avoid any interaction with the cache control headers we expire 29 | ## everything on this location immediately. 30 | expires epoch; 31 | ## Enable clickjacking protection in modern browsers. Available in 32 | ## IE8 also. See 33 | ## https://developer.mozilla.org/en/The_X-FRAME-OPTIONS_response_header 34 | ## This may conflicts with pseudo streaming (at least with Nginx version 1.0.12). 35 | ## Uncomment the line below if you're not using media streaming. 36 | ## For sites *not* using frames uncomment the line below. 37 | #add_header X-Frame-Options DENY; 38 | ## For sites *using* frames uncomment the line below. 39 | #add_header X-Frame-Options SAMEORIGIN; 40 | 41 | ## Block MIME type sniffing on IE. 42 | add_header X-Content-Options nosniff; 43 | 44 | ## Strict Transport Security header for enhanced security. See 45 | ## http://www.chromium.org/sts. I've set it to 2 hours; set it to 46 | ## whichever age you want. 47 | ## Uncomment the line below if you're using HTTPS. 48 | #add_header Strict-Transport-Security max-age=7200; 49 | 50 | ## If you're using a Nginx version greater than 1.1.11 then uncomment 51 | ## the line below. See: 52 | ## http://nginx.org/en/docs/http/ngx_http_fastcgi_module.html#fastcgi_cache_lock 53 | ## Cache locking mechanism for protecting the backend of too many 54 | ## simultaneous requests. 55 | #fastcgi_cache_lock on; 56 | ## The default timeout, i.e., the time to way before forwarding the 57 | ## second request upstream if no reply as arrived in the meantime is 5s. 58 | #fastcgi_cache_lock_timeout 8000; # in miliseconds. -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:14.04 2 | 3 | MAINTAINER Luis Elizondo "lelizondo@gmail.com" 4 | ENV DEBIAN_FRONTEND noninteractive 5 | 6 | # Ensure UTF-8 7 | RUN locale-gen en_US.UTF-8 8 | ENV LANG en_US.UTF-8 9 | ENV LC_ALL en_US.UTF-8 10 | 11 | ENV SMTP_HOST smtp.gmail.com 12 | ENV SMTP_PORT 587 13 | ENV SMTP_FROMNAME My Name 14 | ENV SMTP_USERNAME username@example.com 15 | ENV SMTP_PASSWORD secret 16 | 17 | # Update system 18 | RUN apt-get update && apt-get dist-upgrade -y 19 | 20 | # Prevent restarts when installing 21 | RUN echo '#!/bin/sh\nexit 101' > /usr/sbin/policy-rc.d && chmod +x /usr/sbin/policy-rc.d 22 | 23 | # Basic packages 24 | RUN apt-get -y install php5-fpm php5-mysql php-apc php5-imagick php5-imap php5-mcrypt php5-curl php5-cli php5-gd php5-pgsql php5-sqlite php5-common php-pear curl php5-json php5-redis php5-memcache 25 | RUN apt-get -y install nginx-extras git curl supervisor 26 | RUN apt-get -y install msmtp msmtp-mta 27 | 28 | RUN php5enmod mcrypt 29 | 30 | RUN /usr/bin/curl -sS https://getcomposer.org/installer | /usr/bin/php 31 | RUN /bin/mv composer.phar /usr/local/bin/composer 32 | RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 33 | 34 | # Install Composer and Drush 35 | RUN /usr/local/bin/composer self-update 36 | RUN /usr/local/bin/composer global require drush/drush:6.* 37 | RUN ln -s /root/.composer/vendor/drush/drush/drush /usr/local/bin/drush 38 | 39 | # Prepare directory 40 | RUN mkdir /var/www 41 | RUN usermod -u 1000 www-data 42 | RUN usermod -a -G users www-data 43 | RUN chown -R www-data:www-data /var/www 44 | 45 | EXPOSE 80 46 | WORKDIR /var/www 47 | VOLUME ["/var/www/sites/default/files"] 48 | CMD ["/usr/bin/supervisord", "-n"] 49 | 50 | # Startup script 51 | # This startup script wll configure nginx 52 | ADD ./startup.sh /opt/startup.sh 53 | RUN chmod +x /opt/startup.sh 54 | 55 | ADD ./mail.sh /opt/mail.sh 56 | RUN chmod +x /opt/mail.sh 57 | 58 | ADD ./cron.sh /opt/cron.sh 59 | RUN chmod +x /opt/cron.sh 60 | 61 | # We want it empty 62 | RUN touch /etc/msmtprc 63 | RUN chgrp mail /etc/msmtprc 64 | RUN chmod 660 /etc/msmtprc 65 | RUN touch /var/log/supervisor/msmtp.log 66 | RUN chgrp mail /var/log/supervisor/msmtp.log 67 | RUN chmod 660 /var/log/supervisor/msmtp.log 68 | RUN adduser www-data mail 69 | 70 | RUN rm /usr/sbin/sendmail 71 | RUN rm /usr/lib/sendmail 72 | 73 | RUN ln -s /usr/bin/msmtp /usr/sbin/sendmail 74 | RUN ln -s /usr/bin/msmtp /usr/bin/sendmail 75 | RUN ln -s /usr/bin/msmtp /usr/lib/sendmail 76 | 77 | RUN mkdir -p /var/cache/nginx/microcache 78 | 79 | ### Add configuration files 80 | # Supervisor 81 | ADD ./config/supervisor/supervisord-nginx.conf /etc/supervisor/conf.d/supervisord-nginx.conf 82 | 83 | # PHP 84 | ADD ./config/php/www.conf /etc/php5/fpm/pool.d/www.conf 85 | ADD ./config/php/php.ini /etc/php5/fpm/php.ini 86 | 87 | # Nginx 88 | ADD ./config/nginx/blacklist.conf /etc/nginx/blacklist.conf 89 | ADD ./config/nginx/drupal.conf /etc/nginx/drupal.conf 90 | ADD ./config/nginx/drupal_upload_progress.conf /etc/nginx/drupal_upload_progress.conf 91 | ADD ./config/nginx/fastcgi.conf /etc/nginx/fastcgi.conf 92 | ADD ./config/nginx/fastcgi_drupal.conf /etc/nginx/fastcgi_drupal.conf 93 | ADD ./config/nginx/fastcgi_microcache_zone.conf /etc/nginx/fastcgi_microcache_zone.conf 94 | ADD ./config/nginx/fastcgi_no_args_drupal.conf /etc/nginx/fastcgi_no_args_drupal.conf 95 | ADD ./config/nginx/map_cache.conf /etc/nginx/map_cache.conf 96 | ADD ./config/nginx/microcache_fcgi.conf /etc/nginx/microcache_fcgi.conf 97 | ADD ./config/nginx/microcache_fcgi_auth.conf /etc/nginx/microcache_fcgi_auth.conf 98 | ADD ./config/nginx/mime.types /etc/nginx/mime.types 99 | ADD ./config/nginx/nginx.conf /etc/nginx/nginx.conf 100 | ADD ./config/nginx/upstream_phpcgi_unix.conf /etc/nginx/upstream_phpcgi_unix.conf 101 | ADD ./config/nginx/map_block_http_methods.conf /etc/nginx/map_block_http_methods.conf 102 | ADD ./config/nginx/map_https_fcgi.conf /etc/nginx/map_https_fcgi.conf 103 | ADD ./config/nginx/nginx_status_allowed_hosts.conf /etc/nginx/nginx_status_allowed_hosts.conf 104 | ADD ./config/nginx/cron_allowed_hosts.conf /etc/nginx/cron_allowed_hosts.conf 105 | ADD ./config/nginx/php_fpm_status_allowed_hosts.conf /etc/nginx/php_fpm_status_allowed_hosts.conf 106 | ADD ./config/nginx/default /etc/nginx/sites-enabled/default 107 | 108 | -------------------------------------------------------------------------------- /config/nginx/drupal.conf: -------------------------------------------------------------------------------- 1 | ## The 'default' location. 2 | location / { 3 | 4 | ## Trying to access private files directly returns a 404. 5 | location ^~ /sites/default/files/private/ { 6 | internal; 7 | } 8 | 9 | ## If accessing an image generated by Drupal 6 imagecache, serve it 10 | ## directly if available, if not relay the request to Drupal to (re)generate 11 | ## the image. 12 | location ~* /imagecache/ { 13 | ## Image hotlinking protection. If you want hotlinking 14 | ## protection for your images uncomment the following line. 15 | #include apps/drupal/hotlinking_protection.conf; 16 | 17 | access_log off; 18 | expires 30d; 19 | try_files $uri @drupal; 20 | } 21 | 22 | ## Drupal 7 generated image handling, i.e., imagecache in core. See: 23 | ## http://drupal.org/node/371374. 24 | location ~* /files/styles/ { 25 | ## Image hotlinking protection. If you want hotlinking 26 | ## protection for your images uncomment the following line. 27 | #include apps/drupal/hotlinking_protection.conf; 28 | 29 | access_log off; 30 | expires 30d; 31 | try_files $uri @drupal; 32 | } 33 | 34 | ## Advanced Aggregation module CSS 35 | ## support. http://drupal.org/project/advagg. 36 | location ^~ /sites/default/files/advagg_css/ { 37 | expires max; 38 | add_header ETag ''; 39 | add_header Last-Modified 'Wed, 20 Jan 1988 04:20:42 GMT'; 40 | add_header Accept-Ranges ''; 41 | 42 | location ~* /sites/default/files/advagg_css/css[_[:alnum:]]+\.css$ { 43 | access_log off; 44 | try_files $uri @drupal; 45 | } 46 | } 47 | 48 | ## Advanced Aggregation module JS 49 | ## support. http://drupal.org/project/advagg. 50 | location ^~ /sites/default/files/advagg_js/ { 51 | expires max; 52 | add_header ETag ''; 53 | add_header Last-Modified 'Wed, 20 Jan 1988 04:20:42 GMT'; 54 | add_header Accept-Ranges ''; 55 | 56 | location ~* /sites/default/files/advagg_js/js[_[:alnum:]]+\.js$ { 57 | access_log off; 58 | try_files $uri @drupal; 59 | } 60 | } 61 | 62 | ## All static files will be served directly. 63 | location ~* ^.+\.(?:css|cur|js|jpe?g|gif|htc|ico|png|html|xml|otf|ttf|eot|woff|svg)$ { 64 | access_log off; 65 | expires 30d; 66 | ## No need to bleed constant updates. Send the all shebang in one 67 | ## fell swoop. 68 | tcp_nodelay off; 69 | ## Set the OS file cache. 70 | open_file_cache max=3000 inactive=120s; 71 | open_file_cache_valid 45s; 72 | open_file_cache_min_uses 2; 73 | open_file_cache_errors off; 74 | } 75 | 76 | ## PDFs and powerpoint files handling. 77 | location ~* ^.+\.(?:pdf|pptx?)$ { 78 | expires 30d; 79 | ## No need to bleed constant updates. Send the all shebang in one 80 | ## fell swoop. 81 | tcp_nodelay off; 82 | } 83 | 84 | ## Replicate the Apache directive of Drupal standard 85 | ## .htaccess. Disable access to any code files. Return a 404 to curtail 86 | ## information disclosure. Hide also the text files. 87 | location ~* ^(?:.+\.(?:htaccess|make|txt|engine|inc|info|install|module|profile|po|pot|sh|.*sql|test|theme|tpl(?:\.php)?|xtmpl)|code-style\.pl|/Entries.*|/Repository|/Root|/Tag|/Template)$ { 88 | return 404; 89 | } 90 | 91 | ## First we try the URI and relay to the /index.php?q=$uri&$args if not found. 92 | try_files $uri @drupal; 93 | } 94 | 95 | ########### Security measures ########## 96 | 97 | ## Run the update from the web interface with Drupal 7. 98 | location = /authorize.php { 99 | fastcgi_pass phpcgi; 100 | } 101 | 102 | location = /status.php { 103 | fastcgi_pass phpcgi; 104 | } 105 | 106 | location = /update.php { 107 | #auth_basic "Restricted Access"; # auth realm 108 | #auth_basic_user_file .htpasswd-users; # htpasswd file 109 | fastcgi_pass phpcgi; 110 | } 111 | 112 | location = /install.php { 113 | fastcgi_pass phpcgi; 114 | } 115 | 116 | ## Restrict access to the strictly necessary PHP files. Reducing the 117 | ## scope for exploits. Handling of PHP code and the Drupal event loop. 118 | location @drupal { 119 | ## Include the FastCGI config. 120 | include fastcgi_drupal.conf; 121 | fastcgi_pass phpcgi; 122 | 123 | ## FastCGI microcache. 124 | include microcache_fcgi.conf; 125 | ## FCGI microcache for authenticated users also. 126 | ## Incluir el microcache para usuarios authenticados sin distinción de rutas 127 | ## tiene efectos no esperados 128 | # include microcache_fcgi_auth.conf; 129 | 130 | ## Filefield Upload progress 131 | ## http://drupal.org/project/filefield_nginx_progress support 132 | ## through the NginxUploadProgress modules. 133 | track_uploads uploads 60s; 134 | } 135 | 136 | location @drupal-no-args { 137 | ## Include the specific FastCGI configuration. This is for a 138 | ## FCGI backend like php-cgi or php-fpm. 139 | include fastcgi_no_args_drupal.conf; 140 | fastcgi_pass phpcgi; 141 | 142 | ## FCGI microcache for authenticated users also. 143 | include microcache_fcgi_auth.conf; 144 | } 145 | 146 | ## Disallow access to .bzr, .git, .hg, .svn, .cvs directories: return 147 | ## 404 as not to disclose information. 148 | location ^~ /.bzr { 149 | return 404; 150 | } 151 | 152 | location ^~ /.git { 153 | return 404; 154 | } 155 | 156 | location ^~ /.hg { 157 | return 404; 158 | } 159 | 160 | location ^~ /.svn { 161 | return 404; 162 | } 163 | 164 | location ^~ /.cvs { 165 | return 404; 166 | } 167 | 168 | ## Disallow access to patches directory. 169 | location ^~ /patches { 170 | return 404; 171 | } 172 | 173 | ## Disallow access to drush backup directory. 174 | location ^~ /backup { 175 | return 404; 176 | } 177 | 178 | ## Disable access logs for robots.txt. 179 | location = /robots.txt { 180 | access_log off; 181 | ## Add support for the robotstxt module 182 | ## http://drupal.org/project/robotstxt. 183 | try_files $uri @drupal-no-args; 184 | } 185 | 186 | ## RSS feed support. 187 | location = /rss.xml { 188 | try_files $uri @drupal-no-args; 189 | } 190 | 191 | ## XML Sitemap support. 192 | location = /sitemap.xml { 193 | try_files $uri @drupal-no-args; 194 | } 195 | 196 | ## Support for favicon. Return an 1x1 transparent GIF if it doesn't 197 | ## exist. 198 | location = /favicon.ico { 199 | expires 30d; 200 | try_files /favicon.ico @empty; 201 | } 202 | 203 | ## Return an in memory 1x1 transparent GIF. 204 | location @empty { 205 | expires 30d; 206 | empty_gif; 207 | } 208 | 209 | ## Any other attempt to access PHP files returns a 404. 210 | location ~* ^.+\.php$ { 211 | return 404; 212 | } -------------------------------------------------------------------------------- /config/nginx/mime.types: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-current-dictionary: american -*- 2 | types { 3 | text/html html htm shtml; 4 | text/css css; 5 | text/xml xml; 6 | image/gif gif; 7 | image/jpeg jpeg jpg; 8 | application/javascript js; 9 | application/atom+xml atom; 10 | application/rss+xml rss; 11 | 12 | text/mathml mml; 13 | text/plain txt; 14 | text/vnd.sun.j2me.app-descriptor jad; 15 | text/vnd.wap.wml wml; 16 | text/x-component htc; 17 | 18 | image/png png; 19 | image/tiff tif tiff; 20 | image/vnd.wap.wbmp wbmp; 21 | image/x-icon ico; 22 | image/x-jng jng; 23 | image/x-ms-bmp bmp; 24 | image/svg+xml svg svgz; 25 | image/webp webp; 26 | 27 | application/java-archive jar war ear; 28 | application/json json; 29 | application/mac-binhex40 hqx; 30 | application/msword doc; 31 | application/pdf pdf; 32 | application/postscript ps eps ai; 33 | application/rtf rtf; 34 | application/vnd.ms-excel xls; 35 | application/vnd.ms-powerpoint ppt; 36 | application/vnd.wap.wmlc wmlc; 37 | application/vnd.wap.xhtml+xml xhtml; 38 | application/vnd.google-earth.kml+xml kml; 39 | application/vnd.google-earth.kmz kmz; 40 | application/x-7z-compressed 7z; 41 | application/x-cocoa cco; 42 | application/x-java-archive-diff jardiff; 43 | application/x-java-jnlp-file jnlp; 44 | application/x-makeself run; 45 | application/x-perl pl pm; 46 | application/x-pilot prc pdb; 47 | application/x-rar-compressed rar; 48 | application/x-redhat-package-manager rpm; 49 | application/x-sea sea; 50 | application/x-shockwave-flash swf; 51 | application/x-stuffit sit; 52 | application/x-tcl tcl tk; 53 | application/x-x509-ca-cert der pem crt; 54 | application/x-xpinstall xpi; 55 | application/zip zip; 56 | 57 | application/vnd.oasis.opendocument.chart odc; 58 | application/vnd.oasis.opendocument.chart-template otc; 59 | application/vnd.oasis.opendocument.database odb; 60 | application/vnd.oasis.opendocument.formula odf; 61 | application/vnd.oasis.opendocument.formula-template odft; 62 | application/vnd.oasis.opendocument.graphics odg; 63 | application/vnd.oasis.opendocument.graphics-template otg; 64 | application/vnd.oasis.opendocument.image odi; 65 | application/vnd.oasis.opendocument.image-template oti; 66 | application/vnd.oasis.opendocument.presentation odp; 67 | application/vnd.oasis.opendocument.presentation-template otp; 68 | application/vnd.oasis.opendocument.spreadsheet ods; 69 | application/vnd.oasis.opendocument.spreadsheet-template ots; 70 | application/vnd.oasis.opendocument.text-master otm; 71 | application/vnd.oasis.opendocument.text odt; 72 | application/vnd.oasis.opendocument.text-template ott; 73 | application/vnd.oasis.opendocument.text-web oth; 74 | application/vnd.openofficeorg.extension oxt; 75 | application/vnd.openxmlformats-officedocument.presentationml.presentation pptx; 76 | application/vnd.openxmlformats-officedocument.presentationml.slideshow ppsx; 77 | application/vnd.openxmlformats-officedocument.presentationml.slide sldx; 78 | application/vnd.openxmlformats-officedocument.presentationml.template potx; 79 | application/vnd.openxmlformats-officedocument.spreadsheetml.sheet xlsx; 80 | application/vnd.openxmlformats-officedocument.spreadsheetml.template xltx; 81 | application/vnd.openxmlformats-officedocument.wordprocessingml.document docx; 82 | application/vnd.openxmlformats-officedocument.wordprocessingml.template dotx; 83 | application/vnd.sun.xml.calc sxc; 84 | application/vnd.sun.xml.calc.template stc; 85 | application/vnd.sun.xml.draw sxd; 86 | application/vnd.sun.xml.draw.template std; 87 | application/vnd.sun.xml.impress sxi; 88 | application/vnd.sun.xml.impress.template sti; 89 | application/vnd.sun.xml.math sxm; 90 | application/vnd.sun.xml.writer.global sxg; 91 | application/vnd.sun.xml.writer sxw; 92 | application/vnd.sun.xml.writer.template stw; 93 | 94 | # Mime types for web fonts. Stolen from here: 95 | # http://seconddrawer.com.au/blog/ in part. 96 | application/x-font-ttf ttf; 97 | font/opentype otf; 98 | application/vnd.ms-fontobject eot; 99 | application/font-woff woff; 100 | 101 | application/octet-stream bin exe dll; 102 | application/octet-stream deb; 103 | application/octet-stream dmg; 104 | application/octet-stream iso img; 105 | application/octet-stream msi msp msm; 106 | application/octet-stream vcf; 107 | 108 | audio/midi mid midi kar; 109 | audio/mpeg mpga mpega mp2 mp3; 110 | audio/ogg ogg; 111 | audio/x-m4a m4a; 112 | audio/x-realaudio ra; 113 | audio/webm weba; 114 | 115 | video/3gpp 3gpp 3gp; 116 | video/mp4 mp4; 117 | video/mpeg mpeg mpg mpe; 118 | video/ogg ogv; 119 | video/quicktime mov; 120 | video/webm webm; 121 | video/x-flv flv; 122 | video/x-m4v m4v; 123 | video/x-mng mng; 124 | video/x-ms-asf asx asf; 125 | video/x-ms-wmv wmv; 126 | video/x-msvideo avi; 127 | } 128 | -------------------------------------------------------------------------------- /config/nginx/nginx.conf: -------------------------------------------------------------------------------- 1 | # -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*- 2 | user www-data; 3 | 4 | ## If you're using an Nginx version below 1.3.8 or 1.2. then uncomment 5 | ## the line below and set it to the number of cores of the 6 | ## server. Otherwise nginx will determine it automatically. 7 | #worker_processes 4; 8 | 9 | error_log /var/log/supervisor/nginx.log; 10 | pid /var/run/nginx.pid; 11 | 12 | worker_rlimit_nofile 8192; 13 | 14 | events { 15 | worker_connections 4096; 16 | ## Accept as many connections as possible. 17 | multi_accept on; 18 | } 19 | 20 | http { 21 | ## MIME types. 22 | include /etc/nginx/mime.types; 23 | default_type application/octet-stream; 24 | 25 | ## FastCGI. 26 | include fastcgi.conf; 27 | 28 | ## Default log and error files. 29 | access_log /var/log/supervisor/nginx-access.log; 30 | error_log /var/log/supervisor/nginx-error.log; 31 | 32 | ## Use sendfile() syscall to speed up I/O operations and speed up 33 | ## static file serving. 34 | sendfile on; 35 | ## Handling of IPs in proxied and load balancing situations. 36 | set_real_ip_from 0.0.0.0/32; # all addresses get a real IP. 37 | real_ip_header X-Forwarded-For; # the ip is forwarded from the load balancer/proxy 38 | 39 | ## Define a zone for limiting the number of simultaneous 40 | ## connections nginx accepts. 1m means 32000 simultaneous 41 | ## sessions. We need to define for each server the limit_conn 42 | ## value refering to this or other zones. 43 | ## ** This syntax requires nginx version >= 44 | ## ** 1.1.8. Cf. http://nginx.org/en/CHANGES. If using an older 45 | ## ** version then use the limit_zone directive below 46 | ## ** instead. Comment out this 47 | ## ** one if not using nginx version >= 1.1.8. 48 | limit_conn_zone $binary_remote_addr zone=arbeit:10m; 49 | 50 | ## Define a zone for limiting the number of simultaneous 51 | ## connections nginx accepts. 1m means 32000 simultaneous 52 | ## sessions. We need to define for each server the limit_conn 53 | ## value refering to this or other zones. 54 | ## ** Use this directive for nginx versions below 1.1.8. Uncomment the line below. 55 | #limit_zone arbeit $binary_remote_addr 10m; 56 | 57 | ## Timeouts. 58 | client_body_timeout 60; 59 | client_header_timeout 60; 60 | keepalive_timeout 10 10; 61 | send_timeout 60; 62 | 63 | ## Reset lingering timed out connections. Deflect DDoS. 64 | reset_timedout_connection on; 65 | 66 | ## Body size. 67 | client_max_body_size 25m; 68 | 69 | ## TCP options. 70 | tcp_nodelay on; 71 | ## Optimization of socket handling when using sendfile. 72 | tcp_nopush on; 73 | 74 | ## Compression. 75 | gzip on; 76 | gzip_buffers 16 8k; 77 | gzip_comp_level 1; 78 | gzip_http_version 1.1; 79 | gzip_min_length 10; 80 | gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript image/x-icon application/vnd.ms-fontobject font/opentype application/x-font-ttf; 81 | gzip_vary on; 82 | gzip_proxied any; # Compression for all requests. 83 | ## No need for regexps. See 84 | ## http://wiki.nginx.org/NginxHttpGzipModule#gzip_disable 85 | gzip_disable msie6; 86 | 87 | ## Serve already compressed files directly, bypassing on-the-fly 88 | ## compression. 89 | ## 90 | # Usually you don't make much use of this. It's better to just 91 | # enable gzip_static on the locations you need it. 92 | # gzip_static on; 93 | 94 | ## Hide the Nginx version number. 95 | server_tokens off; 96 | 97 | ## Use a SSL/TLS cache for SSL session resume. This needs to be 98 | ## here (in this context, for session resumption to work. See this 99 | ## thread on the Nginx mailing list: 100 | ## http://nginx.org/pipermail/nginx/2010-November/023736.html. 101 | ssl_session_cache shared:SSL:30m; 102 | ssl_session_timeout 1d; 103 | 104 | ## The server dictates the choice of cipher suites. 105 | ssl_prefer_server_ciphers on; 106 | 107 | ## Use only Perfect Forward Secrecy Ciphers. Fallback on non ECDH 108 | ## for crufty clients. 109 | ssl_ciphers ECDH+aRSA+AESGCM:ECDH+aRSA+SHA384:ECDH+aRSA+SHA256:ECDH:EDH+CAMELLIA:EDH+aRSA:+CAMELLIA256:+AES256:+CAMELLIA128:+AES128:+SSLv3:!aNULL:!eNULL:!LOW:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS:!RC4:!SEED:!ECDSA:CAMELLIA256-SHA:AES256-SHA:CAMELLIA128-SHA:AES128-SHA; 110 | 111 | ## No SSL2 support. Legacy support of SSLv3. 112 | ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2; 113 | 114 | ## Pregenerated Diffie-Hellman parameters. 115 | ssl_dhparam /etc/nginx/dh_param.pem; 116 | 117 | ## Curve to use for ECDH. 118 | ssl_ecdh_curve secp521r1; 119 | 120 | ## Enable OCSP stapling. A better way to revocate server certificates. 121 | #ssl_stapling on; 122 | ## Fill in with your own resolver. 123 | resolver 8.8.8.8; 124 | 125 | ## Uncomment to increase map_hash_bucket_size. If start getting 126 | ## [emerg]: could not build the map_hash, you should increase 127 | ## map_hash_bucket_size: 64 in your 128 | ## logs. Cf. http://wiki.nginx.org/NginxOptimizations. 129 | #map_hash_bucket_size 192; 130 | 131 | ## Uncomment one of the lines below if you start getting this message: 132 | ## "[emerg] could not build the variables_hash, you should increase 133 | ## either variables_hash_max_size: 512 or variables_hash_bucket_size: 64" 134 | ## You only need to increase one. Increasing variables_hash_max_size to 1024 135 | ## was recommended in nginx forum by developers. 136 | ## See this forum topic and responses 137 | ## http://forum.nginx.org/read.php?2,192277,192286#msg-192286 138 | ## See http://wiki.nginx.org/HttpCoreModule#variables_hash_bucket_size 139 | ## The line variables_hash_bucket_size was added for completeness but not 140 | ## changed from default. 141 | variables_hash_max_size 1024; # default 512 142 | #variables_hash_bucket_size 64; # default is 64 143 | 144 | ## For the filefield_nginx_progress module to work. From the 145 | ## README. Reserve 1MB under the name 'uploads' to track uploads. 146 | upload_progress uploads 1m; 147 | 148 | ## Enable the builtin cross-site scripting (XSS) filter available 149 | ## in modern browsers. Usually enabled by default we just 150 | ## reinstate in case it has been somehow disabled for this 151 | ## particular server instance. 152 | ## https://www.owasp.org/index.php/List_of_useful_HTTP_headers. 153 | add_header X-XSS-Protection '1; mode=block'; 154 | 155 | ## Enable clickjacking protection in modern browsers. Available in 156 | ## IE8 also. See 157 | ## https://developer.mozilla.org/en/The_X-FRAME-OPTIONS_response_header 158 | ## This may conflicts with pseudo streaming (at least with Nginx version 1.0.12). 159 | ## Uncomment the line below if you're not using media streaming. 160 | ## For sites being framing on the same domqin uncomment the line below. 161 | #add_header X-Frame-Options SAMEORIGIN; 162 | ## For sites accepting to be framed in any context comment the 163 | ## line below. 164 | #add_header X-Frame-Options DENY; 165 | 166 | ## Block MIME type sniffing on IE. 167 | add_header X-Content-Options nosniff; 168 | 169 | ## Include the upstream servers for PHP FastCGI handling config. 170 | ## This one uses the FCGI process listening on TCP sockets. 171 | #include upstream_phpcgi_tcp.conf; 172 | 173 | ## Include the upstream servers for PHP FastCGI handling 174 | ## configuration. This setup uses UNIX sockets for talking with the 175 | ## upstream. 176 | include upstream_phpcgi_unix.conf; 177 | 178 | ## Include the map to block HTTP methods. 179 | include map_block_http_methods.conf; 180 | 181 | ## If using Nginx version >= 1.1.11 then there's a $https variable 182 | ## that has the value 'on' if the used scheme is https and '' if not. 183 | ## See: http://trac.nginx.org/nginx/changeset/4380/nginx 184 | ## http://trac.nginx.org/nginx/changeset/4333/nginx and 185 | ## http://trac.nginx.org/nginx/changeset/4334/nginx. If using a 186 | ## previous version then uncomment out the line below. 187 | #include map_https_fcgi.conf; 188 | 189 | # Support the X-Forwarded-Proto header for fastcgi. 190 | map $http_x_forwarded_proto $fastcgi_https { 191 | default $https; 192 | http ''; 193 | https on; 194 | } 195 | 196 | ## Include the upstream servers for Apache handling the PHP 197 | ## processes. In this case Nginx functions as a reverse proxy. 198 | #include reverse_proxy.conf; 199 | #include upstream_phpapache.conf; 200 | 201 | ## Include the php-fpm status allowed hosts configuration block. 202 | ## Uncomment to enable if you're running php-fpm. 203 | include php_fpm_status_allowed_hosts.conf; 204 | 205 | ## Include the Nginx stub status allowed hosts configuration block. 206 | include nginx_status_allowed_hosts.conf; 207 | 208 | ## If you want to run cron using Drupal cron.php. i.e., you're not 209 | ## using drush then uncomment the line below. Specify in 210 | ## cron_allowed_hosts.conf which hosts can invole cron. 211 | include cron_allowed_hosts.conf; 212 | 213 | ## Include blacklist for bad bot and referer blocking. 214 | include blacklist.conf; 215 | 216 | ## Include the caching setup. Needed for using Drupal with an external cache. 217 | include map_cache.conf; 218 | 219 | ## Microcache zone definition for FastCGI. 220 | include fastcgi_microcache_zone.conf; 221 | 222 | ## If you're using Apache for handling PHP then comment the line 223 | ## above and uncomment the line below. 224 | #include proxy_microcache_zone.conf 225 | 226 | ## Include all vhosts. 227 | include /etc/nginx/sites-enabled/*; 228 | } 229 | -------------------------------------------------------------------------------- /config/php/www.conf: -------------------------------------------------------------------------------- 1 | ; Start a new pool named 'www'. 2 | ; the variable $pool can we used in any directive and will be replaced by the 3 | ; pool name ('www' here) 4 | [www] 5 | 6 | ; Per pool prefix 7 | ; It only applies on the following directives: 8 | ; - 'slowlog' 9 | ; - 'listen' (unixsocket) 10 | ; - 'chroot' 11 | ; - 'chdir' 12 | ; - 'php_values' 13 | ; - 'php_admin_values' 14 | ; When not set, the global prefix (or /usr) applies instead. 15 | ; Note: This directive can also be relative to the global prefix. 16 | ; Default Value: none 17 | ;prefix = /path/to/pools/$pool 18 | 19 | ; Unix user/group of processes 20 | ; Note: The user is mandatory. If the group is not set, the default user's group 21 | ; will be used. 22 | user = www-data 23 | group = www-data 24 | 25 | ; The address on which to accept FastCGI requests. 26 | ; Valid syntaxes are: 27 | ; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific address on 28 | ; a specific port; 29 | ; 'port' - to listen on a TCP socket to all addresses on a 30 | ; specific port; 31 | ; '/path/to/unix/socket' - to listen on a unix socket. 32 | ; Note: This value is mandatory. 33 | listen = /var/run/php-fpm.sock 34 | 35 | ; Set listen(2) backlog. A value of '-1' means unlimited. 36 | ; Default Value: 128 (-1 on FreeBSD and OpenBSD) 37 | ;listen.backlog = -1 38 | 39 | ; Set permissions for unix socket, if one is used. In Linux, read/write 40 | ; permissions must be set in order to allow connections from a web server. Many 41 | ; BSD-derived systems allow connections regardless of permissions. 42 | ; Default Values: user and group are set as the running user 43 | ; mode is set to 0660 44 | listen.owner = www-data 45 | listen.group = www-data 46 | ;listen.mode = 0660 47 | 48 | ; List of ipv4 addresses of FastCGI clients which are allowed to connect. 49 | ; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original 50 | ; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address 51 | ; must be separated by a comma. If this value is left blank, connections will be 52 | ; accepted from any ip address. 53 | ; Default Value: any 54 | ;listen.allowed_clients = 127.0.0.1 55 | 56 | ; Choose how the process manager will control the number of child processes. 57 | ; Possible Values: 58 | ; static - a fixed number (pm.max_children) of child processes; 59 | ; dynamic - the number of child processes are set dynamically based on the 60 | ; following directives. With this process management, there will be 61 | ; always at least 1 children. 62 | ; pm.max_children - the maximum number of children that can 63 | ; be alive at the same time. 64 | ; pm.start_servers - the number of children created on startup. 65 | ; pm.min_spare_servers - the minimum number of children in 'idle' 66 | ; state (waiting to process). If the number 67 | ; of 'idle' processes is less than this 68 | ; number then some children will be created. 69 | ; pm.max_spare_servers - the maximum number of children in 'idle' 70 | ; state (waiting to process). If the number 71 | ; of 'idle' processes is greater than this 72 | ; number then some children will be killed. 73 | ; ondemand - no children are created at startup. Children will be forked when 74 | ; new requests will connect. The following parameter are used: 75 | ; pm.max_children - the maximum number of children that 76 | ; can be alive at the same time. 77 | ; pm.process_idle_timeout - The number of seconds after which 78 | ; an idle process will be killed. 79 | ; Note: This value is mandatory. 80 | pm = dynamic 81 | 82 | ; The number of child processes to be created when pm is set to 'static' and the 83 | ; maximum number of child processes when pm is set to 'dynamic' or 'ondemand'. 84 | ; This value sets the limit on the number of simultaneous requests that will be 85 | ; served. Equivalent to the ApacheMaxClients directive with mpm_prefork. 86 | ; Equivalent to the PHP_FCGI_CHILDREN environment variable in the original PHP 87 | ; CGI. The below defaults are based on a server without much resources. Don't 88 | ; forget to tweak pm.* to fit your needs. 89 | ; Note: Used when pm is set to 'static', 'dynamic' or 'ondemand' 90 | ; Note: This value is mandatory. 91 | pm.max_children = 10 92 | 93 | ; The number of child processes created on startup. 94 | ; Note: Used only when pm is set to 'dynamic' 95 | ; Default Value: min_spare_servers + (max_spare_servers - min_spare_servers) / 2 96 | pm.start_servers = 4 97 | 98 | ; The desired minimum number of idle server processes. 99 | ; Note: Used only when pm is set to 'dynamic' 100 | ; Note: Mandatory when pm is set to 'dynamic' 101 | pm.min_spare_servers = 2 102 | 103 | ; The desired maximum number of idle server processes. 104 | ; Note: Used only when pm is set to 'dynamic' 105 | ; Note: Mandatory when pm is set to 'dynamic' 106 | pm.max_spare_servers = 6 107 | 108 | ; The number of seconds after which an idle process will be killed. 109 | ; Note: Used only when pm is set to 'ondemand' 110 | ; Default Value: 10s 111 | ;pm.process_idle_timeout = 10s; 112 | 113 | ; The number of requests each child process should execute before respawning. 114 | ; This can be useful to work around memory leaks in 3rd party libraries. For 115 | ; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS. 116 | ; Default Value: 0 117 | ;pm.max_requests = 500 118 | 119 | ; The URI to view the FPM status page. If this value is not set, no URI will be 120 | ; recognized as a status page. It shows the following informations: 121 | ; pool - the name of the pool; 122 | ; process manager - static, dynamic or ondemand; 123 | ; start time - the date and time FPM has started; 124 | ; start since - number of seconds since FPM has started; 125 | ; accepted conn - the number of request accepted by the pool; 126 | ; listen queue - the number of request in the queue of pending 127 | ; connections (see backlog in listen(2)); 128 | ; max listen queue - the maximum number of requests in the queue 129 | ; of pending connections since FPM has started; 130 | ; listen queue len - the size of the socket queue of pending connections; 131 | ; idle processes - the number of idle processes; 132 | ; active processes - the number of active processes; 133 | ; total processes - the number of idle + active processes; 134 | ; max active processes - the maximum number of active processes since FPM 135 | ; has started; 136 | ; max children reached - number of times, the process limit has been reached, 137 | ; when pm tries to start more children (works only for 138 | ; pm 'dynamic' and 'ondemand'); 139 | ; Value are updated in real time. 140 | ; Example output: 141 | ; pool: www 142 | ; process manager: static 143 | ; start time: 01/Jul/2011:17:53:49 +0200 144 | ; start since: 62636 145 | ; accepted conn: 190460 146 | ; listen queue: 0 147 | ; max listen queue: 1 148 | ; listen queue len: 42 149 | ; idle processes: 4 150 | ; active processes: 11 151 | ; total processes: 15 152 | ; max active processes: 12 153 | ; max children reached: 0 154 | ; 155 | ; By default the status page output is formatted as text/plain. Passing either 156 | ; 'html', 'xml' or 'json' in the query string will return the corresponding 157 | ; output syntax. Example: 158 | ; http://www.foo.bar/status 159 | ; http://www.foo.bar/status?json 160 | ; http://www.foo.bar/status?html 161 | ; http://www.foo.bar/status?xml 162 | ; 163 | ; By default the status page only outputs short status. Passing 'full' in the 164 | ; query string will also return status for each pool process. 165 | ; Example: 166 | ; http://www.foo.bar/status?full 167 | ; http://www.foo.bar/status?json&full 168 | ; http://www.foo.bar/status?html&full 169 | ; http://www.foo.bar/status?xml&full 170 | ; The Full status returns for each process: 171 | ; pid - the PID of the process; 172 | ; state - the state of the process (Idle, Running, ...); 173 | ; start time - the date and time the process has started; 174 | ; start since - the number of seconds since the process has started; 175 | ; requests - the number of requests the process has served; 176 | ; request duration - the duration in µs of the requests; 177 | ; request method - the request method (GET, POST, ...); 178 | ; request URI - the request URI with the query string; 179 | ; content length - the content length of the request (only with POST); 180 | ; user - the user (PHP_AUTH_USER) (or '-' if not set); 181 | ; script - the main script called (or '-' if not set); 182 | ; last request cpu - the %cpu the last request consumed 183 | ; it's always 0 if the process is not in Idle state 184 | ; because CPU calculation is done when the request 185 | ; processing has terminated; 186 | ; last request memory - the max amount of memory the last request consumed 187 | ; it's always 0 if the process is not in Idle state 188 | ; because memory calculation is done when the request 189 | ; processing has terminated; 190 | ; If the process is in Idle state, then informations are related to the 191 | ; last request the process has served. Otherwise informations are related to 192 | ; the current request being served. 193 | ; Example output: 194 | ; ************************ 195 | ; pid: 31330 196 | ; state: Running 197 | ; start time: 01/Jul/2011:17:53:49 +0200 198 | ; start since: 63087 199 | ; requests: 12808 200 | ; request duration: 1250261 201 | ; request method: GET 202 | ; request URI: /test_mem.php?N=10000 203 | ; content length: 0 204 | ; user: - 205 | ; script: /home/fat/web/docs/php/test_mem.php 206 | ; last request cpu: 0.00 207 | ; last request memory: 0 208 | ; 209 | ; Note: There is a real-time FPM status monitoring sample web page available 210 | ; It's available in: ${prefix}/share/fpm/status.html 211 | ; 212 | ; Note: The value must start with a leading slash (/). The value can be 213 | ; anything, but it may not be a good idea to use the .php extension or it 214 | ; may conflict with a real PHP file. 215 | ; Default Value: not set 216 | ;pm.status_path = /status 217 | 218 | ; The ping URI to call the monitoring page of FPM. If this value is not set, no 219 | ; URI will be recognized as a ping page. This could be used to test from outside 220 | ; that FPM is alive and responding, or to 221 | ; - create a graph of FPM availability (rrd or such); 222 | ; - remove a server from a group if it is not responding (load balancing); 223 | ; - trigger alerts for the operating team (24/7). 224 | ; Note: The value must start with a leading slash (/). The value can be 225 | ; anything, but it may not be a good idea to use the .php extension or it 226 | ; may conflict with a real PHP file. 227 | ; Default Value: not set 228 | ;ping.path = /ping 229 | 230 | ; This directive may be used to customize the response of a ping request. The 231 | ; response is formatted as text/plain with a 200 response code. 232 | ; Default Value: pong 233 | ;ping.response = pong 234 | 235 | ; The access log file 236 | ; Default: not set 237 | ;access.log = log/$pool.access.log 238 | 239 | ; The access log format. 240 | ; The following syntax is allowed 241 | ; %%: the '%' character 242 | ; %C: %CPU used by the request 243 | ; it can accept the following format: 244 | ; - %{user}C for user CPU only 245 | ; - %{system}C for system CPU only 246 | ; - %{total}C for user + system CPU (default) 247 | ; %d: time taken to serve the request 248 | ; it can accept the following format: 249 | ; - %{seconds}d (default) 250 | ; - %{miliseconds}d 251 | ; - %{mili}d 252 | ; - %{microseconds}d 253 | ; - %{micro}d 254 | ; %e: an environment variable (same as $_ENV or $_SERVER) 255 | ; it must be associated with embraces to specify the name of the env 256 | ; variable. Some exemples: 257 | ; - server specifics like: %{REQUEST_METHOD}e or %{SERVER_PROTOCOL}e 258 | ; - HTTP headers like: %{HTTP_HOST}e or %{HTTP_USER_AGENT}e 259 | ; %f: script filename 260 | ; %l: content-length of the request (for POST request only) 261 | ; %m: request method 262 | ; %M: peak of memory allocated by PHP 263 | ; it can accept the following format: 264 | ; - %{bytes}M (default) 265 | ; - %{kilobytes}M 266 | ; - %{kilo}M 267 | ; - %{megabytes}M 268 | ; - %{mega}M 269 | ; %n: pool name 270 | ; %o: ouput header 271 | ; it must be associated with embraces to specify the name of the header: 272 | ; - %{Content-Type}o 273 | ; - %{X-Powered-By}o 274 | ; - %{Transfert-Encoding}o 275 | ; - .... 276 | ; %p: PID of the child that serviced the request 277 | ; %P: PID of the parent of the child that serviced the request 278 | ; %q: the query string 279 | ; %Q: the '?' character if query string exists 280 | ; %r: the request URI (without the query string, see %q and %Q) 281 | ; %R: remote IP address 282 | ; %s: status (response code) 283 | ; %t: server time the request was received 284 | ; it can accept a strftime(3) format: 285 | ; %d/%b/%Y:%H:%M:%S %z (default) 286 | ; %T: time the log has been written (the request has finished) 287 | ; it can accept a strftime(3) format: 288 | ; %d/%b/%Y:%H:%M:%S %z (default) 289 | ; %u: remote user 290 | ; 291 | ; Default: "%R - %u %t \"%m %r\" %s" 292 | ;access.format = %R - %u %t "%m %r%Q%q" %s %f %{mili}d %{kilo}M %C%% 293 | 294 | ; The log file for slow requests 295 | ; Default Value: not set 296 | ; Note: slowlog is mandatory if request_slowlog_timeout is set 297 | ;slowlog = log/$pool.log.slow 298 | 299 | ; The timeout for serving a single request after which a PHP backtrace will be 300 | ; dumped to the 'slowlog' file. A value of '0s' means 'off'. 301 | ; Available units: s(econds)(default), m(inutes), h(ours), or d(ays) 302 | ; Default Value: 0 303 | ;request_slowlog_timeout = 0 304 | 305 | ; The timeout for serving a single request after which the worker process will 306 | ; be killed. This option should be used when the 'max_execution_time' ini option 307 | ; does not stop script execution for some reason. A value of '0' means 'off'. 308 | ; Available units: s(econds)(default), m(inutes), h(ours), or d(ays) 309 | ; Default Value: 0 310 | ;request_terminate_timeout = 0 311 | 312 | ; Set open file descriptor rlimit. 313 | ; Default Value: system defined value 314 | ;rlimit_files = 1024 315 | 316 | ; Set max core size rlimit. 317 | ; Possible Values: 'unlimited' or an integer greater or equal to 0 318 | ; Default Value: system defined value 319 | ;rlimit_core = 0 320 | 321 | ; Chroot to this directory at the start. This value must be defined as an 322 | ; absolute path. When this value is not set, chroot is not used. 323 | ; Note: you can prefix with '$prefix' to chroot to the pool prefix or one 324 | ; of its subdirectories. If the pool prefix is not set, the global prefix 325 | ; will be used instead. 326 | ; Note: chrooting is a great security feature and should be used whenever 327 | ; possible. However, all PHP paths will be relative to the chroot 328 | ; (error_log, sessions.save_path, ...). 329 | ; Default Value: not set 330 | ;chroot = 331 | 332 | ; Chdir to this directory at the start. 333 | ; Note: relative path can be used. 334 | ; Default Value: current directory or / when chroot 335 | chdir = / 336 | 337 | ; Redirect worker stdout and stderr into main error log. If not set, stdout and 338 | ; stderr will be redirected to /dev/null according to FastCGI specs. 339 | ; Note: on highloaded environement, this can cause some delay in the page 340 | ; process time (several ms). 341 | ; Default Value: no 342 | ;catch_workers_output = yes 343 | 344 | ; Limits the extensions of the main script FPM will allow to parse. This can 345 | ; prevent configuration mistakes on the web server side. You should only limit 346 | ; FPM to .php extensions to prevent malicious users to use other extensions to 347 | ; exectute php code. 348 | ; Note: set an empty value to allow all extensions. 349 | ; Default Value: .php 350 | ;security.limit_extensions = .php .php3 .php4 .php5 351 | 352 | ; Pass environment variables like LD_LIBRARY_PATH. All $VARIABLEs are taken from 353 | ; the current environment. 354 | ; Default Value: clean env 355 | ;env[HOSTNAME] = $HOSTNAME 356 | ;env[PATH] = /usr/local/bin:/usr/bin:/bin 357 | ;env[TMP] = /tmp 358 | ;env[TMPDIR] = /tmp 359 | ;env[TEMP] = /tmp 360 | 361 | ; Additional php.ini defines, specific to this pool of workers. These settings 362 | ; overwrite the values previously defined in the php.ini. The directives are the 363 | ; same as the PHP SAPI: 364 | ; php_value/php_flag - you can set classic ini defines which can 365 | ; be overwritten from PHP call 'ini_set'. 366 | ; php_admin_value/php_admin_flag - these directives won't be overwritten by 367 | ; PHP call 'ini_set' 368 | ; For php_*flag, valid values are on, off, 1, 0, true, false, yes or no. 369 | 370 | ; Defining 'extension' will load the corresponding shared extension from 371 | ; extension_dir. Defining 'disable_functions' or 'disable_classes' will not 372 | ; overwrite previously defined php.ini values, but will append the new value 373 | ; instead. 374 | 375 | ; Note: path INI options can be relative and will be expanded with the prefix 376 | ; (pool, global or /usr) 377 | 378 | ; Default Value: nothing is defined by default except the values in php.ini and 379 | ; specified at startup with the -d argument 380 | ;php_admin_value[sendmail_path] = /usr/sbin/sendmail -t -i -f www@my.domain.com 381 | ;php_flag[display_errors] = off 382 | ;php_admin_value[error_log] = /var/log/fpm-php.www.log 383 | ;php_admin_flag[log_errors] = on 384 | ;php_admin_value[memory_limit] = 32M 385 | -------------------------------------------------------------------------------- /config/php/php.ini: -------------------------------------------------------------------------------- 1 | [PHP] 2 | 3 | ;;;;;;;;;;;;;;;;;;; 4 | ; About php.ini ; 5 | ;;;;;;;;;;;;;;;;;;; 6 | ; PHP's initialization file, generally called php.ini, is responsible for 7 | ; configuring many of the aspects of PHP's behavior. 8 | 9 | ; PHP attempts to find and load this configuration from a number of locations. 10 | ; The following is a summary of its search order: 11 | ; 1. SAPI module specific location. 12 | ; 2. The PHPRC environment variable. (As of PHP 5.2.0) 13 | ; 3. A number of predefined registry keys on Windows (As of PHP 5.2.0) 14 | ; 4. Current working directory (except CLI) 15 | ; 5. The web server's directory (for SAPI modules), or directory of PHP 16 | ; (otherwise in Windows) 17 | ; 6. The directory from the --with-config-file-path compile time option, or the 18 | ; Windows directory (C:\windows or C:\winnt) 19 | ; See the PHP docs for more specific information. 20 | ; http://php.net/configuration.file 21 | 22 | ; The syntax of the file is extremely simple. Whitespace and Lines 23 | ; beginning with a semicolon are silently ignored (as you probably guessed). 24 | ; Section headers (e.g. [Foo]) are also silently ignored, even though 25 | ; they might mean something in the future. 26 | 27 | ; Directives following the section heading [PATH=/www/mysite] only 28 | ; apply to PHP files in the /www/mysite directory. Directives 29 | ; following the section heading [HOST=www.example.com] only apply to 30 | ; PHP files served from www.example.com. Directives set in these 31 | ; special sections cannot be overridden by user-defined INI files or 32 | ; at runtime. Currently, [PATH=] and [HOST=] sections only work under 33 | ; CGI/FastCGI. 34 | ; http://php.net/ini.sections 35 | 36 | ; Directives are specified using the following syntax: 37 | ; directive = value 38 | ; Directive names are *case sensitive* - foo=bar is different from FOO=bar. 39 | ; Directives are variables used to configure PHP or PHP extensions. 40 | ; There is no name validation. If PHP can't find an expected 41 | ; directive because it is not set or is mistyped, a default value will be used. 42 | 43 | ; The value can be a string, a number, a PHP constant (e.g. E_ALL or M_PI), one 44 | ; of the INI constants (On, Off, True, False, Yes, No and None) or an expression 45 | ; (e.g. E_ALL & ~E_NOTICE), a quoted string ("bar"), or a reference to a 46 | ; previously set variable or directive (e.g. ${foo}) 47 | 48 | ; Expressions in the INI file are limited to bitwise operators and parentheses: 49 | ; | bitwise OR 50 | ; ^ bitwise XOR 51 | ; & bitwise AND 52 | ; ~ bitwise NOT 53 | ; ! boolean NOT 54 | 55 | ; Boolean flags can be turned on using the values 1, On, True or Yes. 56 | ; They can be turned off using the values 0, Off, False or No. 57 | 58 | ; An empty string can be denoted by simply not writing anything after the equal 59 | ; sign, or by using the None keyword: 60 | 61 | ; foo = ; sets foo to an empty string 62 | ; foo = None ; sets foo to an empty string 63 | ; foo = "None" ; sets foo to the string 'None' 64 | 65 | ; If you use constants in your value, and these constants belong to a 66 | ; dynamically loaded extension (either a PHP extension or a Zend extension), 67 | ; you may only use these constants *after* the line that loads the extension. 68 | 69 | ;;;;;;;;;;;;;;;;;;; 70 | ; About this file ; 71 | ;;;;;;;;;;;;;;;;;;; 72 | ; PHP comes packaged with two INI files. One that is recommended to be used 73 | ; in production environments and one that is recommended to be used in 74 | ; development environments. 75 | 76 | ; php.ini-production contains settings which hold security, performance and 77 | ; best practices at its core. But please be aware, these settings may break 78 | ; compatibility with older or less security conscience applications. We 79 | ; recommending using the production ini in production and testing environments. 80 | 81 | ; php.ini-development is very similar to its production variant, except it's 82 | ; much more verbose when it comes to errors. We recommending using the 83 | ; development version only in development environments as errors shown to 84 | ; application users can inadvertently leak otherwise secure information. 85 | 86 | ;;;;;;;;;;;;;;;;;;; 87 | ; Quick Reference ; 88 | ;;;;;;;;;;;;;;;;;;; 89 | ; The following are all the settings which are different in either the production 90 | ; or development versions of the INIs with respect to PHP's default behavior. 91 | ; Please see the actual settings later in the document for more details as to why 92 | ; we recommend these changes in PHP's behavior. 93 | 94 | ; allow_call_time_pass_reference 95 | ; Default Value: On 96 | ; Development Value: Off 97 | ; Production Value: Off 98 | 99 | ; display_errors 100 | ; Default Value: On 101 | ; Development Value: On 102 | ; Production Value: Off 103 | 104 | ; display_startup_errors 105 | ; Default Value: Off 106 | ; Development Value: On 107 | ; Production Value: Off 108 | 109 | ; error_reporting 110 | ; Default Value: E_ALL & ~E_NOTICE 111 | ; Development Value: E_ALL | E_STRICT 112 | ; Production Value: E_ALL & ~E_DEPRECATED 113 | 114 | ; html_errors 115 | ; Default Value: On 116 | ; Development Value: On 117 | ; Production value: Off 118 | 119 | ; log_errors 120 | ; Default Value: Off 121 | ; Development Value: On 122 | ; Production Value: On 123 | 124 | ; magic_quotes_gpc 125 | ; Default Value: On 126 | ; Development Value: Off 127 | ; Production Value: Off 128 | 129 | ; max_input_time 130 | ; Default Value: -1 (Unlimited) 131 | ; Development Value: 60 (60 seconds) 132 | ; Production Value: 60 (60 seconds) 133 | 134 | ; output_buffering 135 | ; Default Value: Off 136 | ; Development Value: 4096 137 | ; Production Value: 4096 138 | 139 | ; register_argc_argv 140 | ; Default Value: On 141 | ; Development Value: Off 142 | ; Production Value: Off 143 | 144 | ; register_long_arrays 145 | ; Default Value: On 146 | ; Development Value: Off 147 | ; Production Value: Off 148 | 149 | ; request_order 150 | ; Default Value: None 151 | ; Development Value: "GP" 152 | ; Production Value: "GP" 153 | 154 | ; session.bug_compat_42 155 | ; Default Value: On 156 | ; Development Value: On 157 | ; Production Value: Off 158 | 159 | ; session.bug_compat_warn 160 | ; Default Value: On 161 | ; Development Value: On 162 | ; Production Value: Off 163 | 164 | ; session.gc_divisor 165 | ; Default Value: 100 166 | ; Development Value: 1000 167 | ; Production Value: 1000 168 | 169 | ; session.hash_bits_per_character 170 | ; Default Value: 4 171 | ; Development Value: 5 172 | ; Production Value: 5 173 | 174 | ; short_open_tag 175 | ; Default Value: On 176 | ; Development Value: Off 177 | ; Production Value: Off 178 | 179 | ; track_errors 180 | ; Default Value: Off 181 | ; Development Value: On 182 | ; Production Value: Off 183 | 184 | ; url_rewriter.tags 185 | ; Default Value: "a=href,area=href,frame=src,form=,fieldset=" 186 | ; Development Value: "a=href,area=href,frame=src,input=src,form=fakeentry" 187 | ; Production Value: "a=href,area=href,frame=src,input=src,form=fakeentry" 188 | 189 | ; variables_order 190 | ; Default Value: "EGPCS" 191 | ; Development Value: "GPCS" 192 | ; Production Value: "GPCS" 193 | 194 | ;;;;;;;;;;;;;;;;;;;; 195 | ; php.ini Options ; 196 | ;;;;;;;;;;;;;;;;;;;; 197 | ; Name for user-defined php.ini (.htaccess) files. Default is ".user.ini" 198 | ;user_ini.filename = ".user.ini" 199 | 200 | ; To disable this feature set this option to empty value 201 | ;user_ini.filename = 202 | 203 | ; TTL for user-defined php.ini files (time-to-live) in seconds. Default is 300 seconds (5 minutes) 204 | ;user_ini.cache_ttl = 300 205 | 206 | ;;;;;;;;;;;;;;;;;;;; 207 | ; Language Options ; 208 | ;;;;;;;;;;;;;;;;;;;; 209 | 210 | ; Enable the PHP scripting language engine under Apache. 211 | ; http://php.net/engine 212 | engine = On 213 | 214 | ; This directive determines whether or not PHP will recognize code between 215 | ; tags as PHP source which should be processed as such. It's been 216 | ; recommended for several years that you not use the short tag "short cut" and 217 | ; instead to use the full tag combination. With the wide spread use 218 | ; of XML and use of these tags by other languages, the server can become easily 219 | ; confused and end up parsing the wrong code in the wrong context. But because 220 | ; this short cut has been a feature for such a long time, it's currently still 221 | ; supported for backwards compatibility, but we recommend you don't use them. 222 | ; Default Value: On 223 | ; Development Value: Off 224 | ; Production Value: Off 225 | ; http://php.net/short-open-tag 226 | short_open_tag = On 227 | 228 | ; Allow ASP-style <% %> tags. 229 | ; http://php.net/asp-tags 230 | asp_tags = Off 231 | 232 | ; The number of significant digits displayed in floating point numbers. 233 | ; http://php.net/precision 234 | precision = 14 235 | 236 | ; Enforce year 2000 compliance (will cause problems with non-compliant browsers) 237 | ; http://php.net/y2k-compliance 238 | y2k_compliance = On 239 | 240 | ; Output buffering is a mechanism for controlling how much output data 241 | ; (excluding headers and cookies) PHP should keep internally before pushing that 242 | ; data to the client. If your application's output exceeds this setting, PHP 243 | ; will send that data in chunks of roughly the size you specify. 244 | ; Turning on this setting and managing its maximum buffer size can yield some 245 | ; interesting side-effects depending on your application and web server. 246 | ; You may be able to send headers and cookies after you've already sent output 247 | ; through print or echo. You also may see performance benefits if your server is 248 | ; emitting less packets due to buffered output versus PHP streaming the output 249 | ; as it gets it. On production servers, 4096 bytes is a good setting for performance 250 | ; reasons. 251 | ; Note: Output buffering can also be controlled via Output Buffering Control 252 | ; functions. 253 | ; Possible Values: 254 | ; On = Enabled and buffer is unlimited. (Use with caution) 255 | ; Off = Disabled 256 | ; Integer = Enables the buffer and sets its maximum size in bytes. 257 | ; Note: This directive is hardcoded to Off for the CLI SAPI 258 | ; Default Value: Off 259 | ; Development Value: 4096 260 | ; Production Value: 4096 261 | ; http://php.net/output-buffering 262 | output_buffering = 4096 263 | 264 | ; You can redirect all of the output of your scripts to a function. For 265 | ; example, if you set output_handler to "mb_output_handler", character 266 | ; encoding will be transparently converted to the specified encoding. 267 | ; Setting any output handler automatically turns on output buffering. 268 | ; Note: People who wrote portable scripts should not depend on this ini 269 | ; directive. Instead, explicitly set the output handler using ob_start(). 270 | ; Using this ini directive may cause problems unless you know what script 271 | ; is doing. 272 | ; Note: You cannot use both "mb_output_handler" with "ob_iconv_handler" 273 | ; and you cannot use both "ob_gzhandler" and "zlib.output_compression". 274 | ; Note: output_handler must be empty if this is set 'On' !!!! 275 | ; Instead you must use zlib.output_handler. 276 | ; http://php.net/output-handler 277 | ;output_handler = 278 | 279 | ; Transparent output compression using the zlib library 280 | ; Valid values for this option are 'off', 'on', or a specific buffer size 281 | ; to be used for compression (default is 4KB) 282 | ; Note: Resulting chunk size may vary due to nature of compression. PHP 283 | ; outputs chunks that are few hundreds bytes each as a result of 284 | ; compression. If you prefer a larger chunk size for better 285 | ; performance, enable output_buffering in addition. 286 | ; Note: You need to use zlib.output_handler instead of the standard 287 | ; output_handler, or otherwise the output will be corrupted. 288 | ; http://php.net/zlib.output-compression 289 | zlib.output_compression = Off 290 | 291 | ; http://php.net/zlib.output-compression-level 292 | ;zlib.output_compression_level = -1 293 | 294 | ; You cannot specify additional output handlers if zlib.output_compression 295 | ; is activated here. This setting does the same as output_handler but in 296 | ; a different order. 297 | ; http://php.net/zlib.output-handler 298 | ;zlib.output_handler = 299 | 300 | ; Implicit flush tells PHP to tell the output layer to flush itself 301 | ; automatically after every output block. This is equivalent to calling the 302 | ; PHP function flush() after each and every call to print() or echo() and each 303 | ; and every HTML block. Turning this option on has serious performance 304 | ; implications and is generally recommended for debugging purposes only. 305 | ; http://php.net/implicit-flush 306 | ; Note: This directive is hardcoded to On for the CLI SAPI 307 | implicit_flush = Off 308 | 309 | ; The unserialize callback function will be called (with the undefined class' 310 | ; name as parameter), if the unserializer finds an undefined class 311 | ; which should be instantiated. A warning appears if the specified function is 312 | ; not defined, or if the function doesn't include/implement the missing class. 313 | ; So only set this entry, if you really want to implement such a 314 | ; callback-function. 315 | unserialize_callback_func = 316 | 317 | ; When floats & doubles are serialized store serialize_precision significant 318 | ; digits after the floating point. The default value ensures that when floats 319 | ; are decoded with unserialize, the data will remain the same. 320 | serialize_precision = 17 321 | 322 | ; This directive allows you to enable and disable warnings which PHP will issue 323 | ; if you pass a value by reference at function call time. Passing values by 324 | ; reference at function call time is a deprecated feature which will be removed 325 | ; from PHP at some point in the near future. The acceptable method for passing a 326 | ; value by reference to a function is by declaring the reference in the functions 327 | ; definition, not at call time. This directive does not disable this feature, it 328 | ; only determines whether PHP will warn you about it or not. These warnings 329 | ; should enabled in development environments only. 330 | ; Default Value: On (Suppress warnings) 331 | ; Development Value: Off (Issue warnings) 332 | ; Production Value: Off (Issue warnings) 333 | ; http://php.net/allow-call-time-pass-reference 334 | allow_call_time_pass_reference = Off 335 | 336 | ; Safe Mode 337 | ; http://php.net/safe-mode 338 | safe_mode = Off 339 | 340 | ; By default, Safe Mode does a UID compare check when 341 | ; opening files. If you want to relax this to a GID compare, 342 | ; then turn on safe_mode_gid. 343 | ; http://php.net/safe-mode-gid 344 | safe_mode_gid = Off 345 | 346 | ; When safe_mode is on, UID/GID checks are bypassed when 347 | ; including files from this directory and its subdirectories. 348 | ; (directory must also be in include_path or full path must 349 | ; be used when including) 350 | ; http://php.net/safe-mode-include-dir 351 | safe_mode_include_dir = 352 | 353 | ; When safe_mode is on, only executables located in the safe_mode_exec_dir 354 | ; will be allowed to be executed via the exec family of functions. 355 | ; http://php.net/safe-mode-exec-dir 356 | safe_mode_exec_dir = 357 | 358 | ; Setting certain environment variables may be a potential security breach. 359 | ; This directive contains a comma-delimited list of prefixes. In Safe Mode, 360 | ; the user may only alter environment variables whose names begin with the 361 | ; prefixes supplied here. By default, users will only be able to set 362 | ; environment variables that begin with PHP_ (e.g. PHP_FOO=BAR). 363 | ; Note: If this directive is empty, PHP will let the user modify ANY 364 | ; environment variable! 365 | ; http://php.net/safe-mode-allowed-env-vars 366 | safe_mode_allowed_env_vars = PHP_ 367 | 368 | ; This directive contains a comma-delimited list of environment variables that 369 | ; the end user won't be able to change using putenv(). These variables will be 370 | ; protected even if safe_mode_allowed_env_vars is set to allow to change them. 371 | ; http://php.net/safe-mode-protected-env-vars 372 | safe_mode_protected_env_vars = LD_LIBRARY_PATH 373 | 374 | ; open_basedir, if set, limits all file operations to the defined directory 375 | ; and below. This directive makes most sense if used in a per-directory 376 | ; or per-virtualhost web server configuration file. This directive is 377 | ; *NOT* affected by whether Safe Mode is turned On or Off. 378 | ; http://php.net/open-basedir 379 | ;open_basedir = 380 | 381 | ; This directive allows you to disable certain functions for security reasons. 382 | ; It receives a comma-delimited list of function names. This directive is 383 | ; *NOT* affected by whether Safe Mode is turned On or Off. 384 | ; http://php.net/disable-functions 385 | disable_functions = pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, 386 | 387 | ; This directive allows you to disable certain classes for security reasons. 388 | ; It receives a comma-delimited list of class names. This directive is 389 | ; *NOT* affected by whether Safe Mode is turned On or Off. 390 | ; http://php.net/disable-classes 391 | disable_classes = 392 | 393 | ; Colors for Syntax Highlighting mode. Anything that's acceptable in 394 | ; would work. 395 | ; http://php.net/syntax-highlighting 396 | ;highlight.string = #DD0000 397 | ;highlight.comment = #FF9900 398 | ;highlight.keyword = #007700 399 | ;highlight.bg = #FFFFFF 400 | ;highlight.default = #0000BB 401 | ;highlight.html = #000000 402 | 403 | ; If enabled, the request will be allowed to complete even if the user aborts 404 | ; the request. Consider enabling it if executing long requests, which may end up 405 | ; being interrupted by the user or a browser timing out. PHP's default behavior 406 | ; is to disable this feature. 407 | ; http://php.net/ignore-user-abort 408 | ;ignore_user_abort = On 409 | 410 | ; Determines the size of the realpath cache to be used by PHP. This value should 411 | ; be increased on systems where PHP opens many files to reflect the quantity of 412 | ; the file operations performed. 413 | ; http://php.net/realpath-cache-size 414 | ;realpath_cache_size = 16k 415 | 416 | ; Duration of time, in seconds for which to cache realpath information for a given 417 | ; file or directory. For systems with rarely changing files, consider increasing this 418 | ; value. 419 | ; http://php.net/realpath-cache-ttl 420 | ;realpath_cache_ttl = 120 421 | 422 | ; Enables or disables the circular reference collector. 423 | ; http://php.net/zend.enable-gc 424 | zend.enable_gc = On 425 | 426 | ;;;;;;;;;;;;;;;;; 427 | ; Miscellaneous ; 428 | ;;;;;;;;;;;;;;;;; 429 | 430 | ; Decides whether PHP may expose the fact that it is installed on the server 431 | ; (e.g. by adding its signature to the Web server header). It is no security 432 | ; threat in any way, but it makes it possible to determine whether you use PHP 433 | ; on your server or not. 434 | ; http://php.net/expose-php 435 | expose_php = On 436 | 437 | ;;;;;;;;;;;;;;;;;;; 438 | ; Resource Limits ; 439 | ;;;;;;;;;;;;;;;;;;; 440 | 441 | ; Maximum execution time of each script, in seconds 442 | ; http://php.net/max-execution-time 443 | ; Note: This directive is hardcoded to 0 for the CLI SAPI 444 | max_execution_time = 30 445 | 446 | ; Maximum amount of time each script may spend parsing request data. It's a good 447 | ; idea to limit this time on productions servers in order to eliminate unexpectedly 448 | ; long running scripts. 449 | ; Note: This directive is hardcoded to -1 for the CLI SAPI 450 | ; Default Value: -1 (Unlimited) 451 | ; Development Value: 60 (60 seconds) 452 | ; Production Value: 60 (60 seconds) 453 | ; http://php.net/max-input-time 454 | max_input_time = 60 455 | 456 | ; Maximum input variable nesting level 457 | ; http://php.net/max-input-nesting-level 458 | ;max_input_nesting_level = 64 459 | 460 | ; How many GET/POST/COOKIE input variables may be accepted 461 | ; max_input_vars = 1000 462 | 463 | ; Maximum amount of memory a script may consume (128MB) 464 | ; http://php.net/memory-limit 465 | memory_limit = 196M 466 | 467 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 468 | ; Error handling and logging ; 469 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 470 | 471 | ; This directive informs PHP of which errors, warnings and notices you would like 472 | ; it to take action for. The recommended way of setting values for this 473 | ; directive is through the use of the error level constants and bitwise 474 | ; operators. The error level constants are below here for convenience as well as 475 | ; some common settings and their meanings. 476 | ; By default, PHP is set to take action on all errors, notices and warnings EXCEPT 477 | ; those related to E_NOTICE and E_STRICT, which together cover best practices and 478 | ; recommended coding standards in PHP. For performance reasons, this is the 479 | ; recommend error reporting setting. Your production server shouldn't be wasting 480 | ; resources complaining about best practices and coding standards. That's what 481 | ; development servers and development settings are for. 482 | ; Note: The php.ini-development file has this setting as E_ALL | E_STRICT. This 483 | ; means it pretty much reports everything which is exactly what you want during 484 | ; development and early testing. 485 | ; 486 | ; Error Level Constants: 487 | ; E_ALL - All errors and warnings (includes E_STRICT as of PHP 6.0.0) 488 | ; E_ERROR - fatal run-time errors 489 | ; E_RECOVERABLE_ERROR - almost fatal run-time errors 490 | ; E_WARNING - run-time warnings (non-fatal errors) 491 | ; E_PARSE - compile-time parse errors 492 | ; E_NOTICE - run-time notices (these are warnings which often result 493 | ; from a bug in your code, but it's possible that it was 494 | ; intentional (e.g., using an uninitialized variable and 495 | ; relying on the fact it's automatically initialized to an 496 | ; empty string) 497 | ; E_STRICT - run-time notices, enable to have PHP suggest changes 498 | ; to your code which will ensure the best interoperability 499 | ; and forward compatibility of your code 500 | ; E_CORE_ERROR - fatal errors that occur during PHP's initial startup 501 | ; E_CORE_WARNING - warnings (non-fatal errors) that occur during PHP's 502 | ; initial startup 503 | ; E_COMPILE_ERROR - fatal compile-time errors 504 | ; E_COMPILE_WARNING - compile-time warnings (non-fatal errors) 505 | ; E_USER_ERROR - user-generated error message 506 | ; E_USER_WARNING - user-generated warning message 507 | ; E_USER_NOTICE - user-generated notice message 508 | ; E_DEPRECATED - warn about code that will not work in future versions 509 | ; of PHP 510 | ; E_USER_DEPRECATED - user-generated deprecation warnings 511 | ; 512 | ; Common Values: 513 | ; E_ALL & ~E_NOTICE (Show all errors, except for notices and coding standards warnings.) 514 | ; E_ALL & ~E_NOTICE | E_STRICT (Show all errors, except for notices) 515 | ; E_COMPILE_ERROR|E_RECOVERABLE_ERROR|E_ERROR|E_CORE_ERROR (Show only errors) 516 | ; E_ALL | E_STRICT (Show all errors, warnings and notices including coding standards.) 517 | ; Default Value: E_ALL & ~E_NOTICE 518 | ; Development Value: E_ALL | E_STRICT 519 | ; Production Value: E_ALL & ~E_DEPRECATED 520 | ; http://php.net/error-reporting 521 | error_reporting = E_ALL & ~E_DEPRECATED 522 | 523 | ; This directive controls whether or not and where PHP will output errors, 524 | ; notices and warnings too. Error output is very useful during development, but 525 | ; it could be very dangerous in production environments. Depending on the code 526 | ; which is triggering the error, sensitive information could potentially leak 527 | ; out of your application such as database usernames and passwords or worse. 528 | ; It's recommended that errors be logged on production servers rather than 529 | ; having the errors sent to STDOUT. 530 | ; Possible Values: 531 | ; Off = Do not display any errors 532 | ; stderr = Display errors to STDERR (affects only CGI/CLI binaries!) 533 | ; On or stdout = Display errors to STDOUT 534 | ; Default Value: On 535 | ; Development Value: On 536 | ; Production Value: Off 537 | ; http://php.net/display-errors 538 | display_errors = Off 539 | 540 | ; The display of errors which occur during PHP's startup sequence are handled 541 | ; separately from display_errors. PHP's default behavior is to suppress those 542 | ; errors from clients. Turning the display of startup errors on can be useful in 543 | ; debugging configuration problems. But, it's strongly recommended that you 544 | ; leave this setting off on production servers. 545 | ; Default Value: Off 546 | ; Development Value: On 547 | ; Production Value: Off 548 | ; http://php.net/display-startup-errors 549 | display_startup_errors = Off 550 | 551 | ; Besides displaying errors, PHP can also log errors to locations such as a 552 | ; server-specific log, STDERR, or a location specified by the error_log 553 | ; directive found below. While errors should not be displayed on productions 554 | ; servers they should still be monitored and logging is a great way to do that. 555 | ; Default Value: Off 556 | ; Development Value: On 557 | ; Production Value: On 558 | ; http://php.net/log-errors 559 | log_errors = On 560 | 561 | ; Set maximum length of log_errors. In error_log information about the source is 562 | ; added. The default is 1024 and 0 allows to not apply any maximum length at all. 563 | ; http://php.net/log-errors-max-len 564 | log_errors_max_len = 1024 565 | 566 | ; Do not log repeated messages. Repeated errors must occur in same file on same 567 | ; line unless ignore_repeated_source is set true. 568 | ; http://php.net/ignore-repeated-errors 569 | ignore_repeated_errors = Off 570 | 571 | ; Ignore source of message when ignoring repeated messages. When this setting 572 | ; is On you will not log errors with repeated messages from different files or 573 | ; source lines. 574 | ; http://php.net/ignore-repeated-source 575 | ignore_repeated_source = Off 576 | 577 | ; If this parameter is set to Off, then memory leaks will not be shown (on 578 | ; stdout or in the log). This has only effect in a debug compile, and if 579 | ; error reporting includes E_WARNING in the allowed list 580 | ; http://php.net/report-memleaks 581 | report_memleaks = On 582 | 583 | ; This setting is on by default. 584 | ;report_zend_debug = 0 585 | 586 | ; Store the last error/warning message in $php_errormsg (boolean). Setting this value 587 | ; to On can assist in debugging and is appropriate for development servers. It should 588 | ; however be disabled on production servers. 589 | ; Default Value: Off 590 | ; Development Value: On 591 | ; Production Value: Off 592 | ; http://php.net/track-errors 593 | track_errors = Off 594 | 595 | ; Turn off normal error reporting and emit XML-RPC error XML 596 | ; http://php.net/xmlrpc-errors 597 | ;xmlrpc_errors = 0 598 | 599 | ; An XML-RPC faultCode 600 | ;xmlrpc_error_number = 0 601 | 602 | ; When PHP displays or logs an error, it has the capability of inserting html 603 | ; links to documentation related to that error. This directive controls whether 604 | ; those HTML links appear in error messages or not. For performance and security 605 | ; reasons, it's recommended you disable this on production servers. 606 | ; Note: This directive is hardcoded to Off for the CLI SAPI 607 | ; Default Value: On 608 | ; Development Value: On 609 | ; Production value: Off 610 | ; http://php.net/html-errors 611 | html_errors = Off 612 | 613 | ; If html_errors is set On PHP produces clickable error messages that direct 614 | ; to a page describing the error or function causing the error in detail. 615 | ; You can download a copy of the PHP manual from http://php.net/docs 616 | ; and change docref_root to the base URL of your local copy including the 617 | ; leading '/'. You must also specify the file extension being used including 618 | ; the dot. PHP's default behavior is to leave these settings empty. 619 | ; Note: Never use this feature for production boxes. 620 | ; http://php.net/docref-root 621 | ; Examples 622 | ;docref_root = "/phpmanual/" 623 | 624 | ; http://php.net/docref-ext 625 | ;docref_ext = .html 626 | 627 | ; String to output before an error message. PHP's default behavior is to leave 628 | ; this setting blank. 629 | ; http://php.net/error-prepend-string 630 | ; Example: 631 | ;error_prepend_string = "" 632 | 633 | ; String to output after an error message. PHP's default behavior is to leave 634 | ; this setting blank. 635 | ; http://php.net/error-append-string 636 | ; Example: 637 | ;error_append_string = "" 638 | 639 | ; Log errors to specified file. PHP's default behavior is to leave this value 640 | ; empty. 641 | ; http://php.net/error-log 642 | ; Example: 643 | error_log = /var/log/supervisor/php-errors.log 644 | ; Log errors to syslog (Event Log on NT, not valid in Windows 95). 645 | ;error_log = syslog 646 | 647 | ;windows.show_crt_warning 648 | ; Default value: 0 649 | ; Development value: 0 650 | ; Production value: 0 651 | 652 | ;;;;;;;;;;;;;;;;; 653 | ; Data Handling ; 654 | ;;;;;;;;;;;;;;;;; 655 | 656 | ; The separator used in PHP generated URLs to separate arguments. 657 | ; PHP's default setting is "&". 658 | ; http://php.net/arg-separator.output 659 | ; Example: 660 | ;arg_separator.output = "&" 661 | 662 | ; List of separator(s) used by PHP to parse input URLs into variables. 663 | ; PHP's default setting is "&". 664 | ; NOTE: Every character in this directive is considered as separator! 665 | ; http://php.net/arg-separator.input 666 | ; Example: 667 | ;arg_separator.input = ";&" 668 | 669 | ; This directive determines which super global arrays are registered when PHP 670 | ; starts up. If the register_globals directive is enabled, it also determines 671 | ; what order variables are populated into the global space. G,P,C,E & S are 672 | ; abbreviations for the following respective super globals: GET, POST, COOKIE, 673 | ; ENV and SERVER. There is a performance penalty paid for the registration of 674 | ; these arrays and because ENV is not as commonly used as the others, ENV is 675 | ; is not recommended on productions servers. You can still get access to 676 | ; the environment variables through getenv() should you need to. 677 | ; Default Value: "EGPCS" 678 | ; Development Value: "GPCS" 679 | ; Production Value: "GPCS"; 680 | ; http://php.net/variables-order 681 | variables_order = "GPCS" 682 | 683 | ; This directive determines which super global data (G,P,C,E & S) should 684 | ; be registered into the super global array REQUEST. If so, it also determines 685 | ; the order in which that data is registered. The values for this directive are 686 | ; specified in the same manner as the variables_order directive, EXCEPT one. 687 | ; Leaving this value empty will cause PHP to use the value set in the 688 | ; variables_order directive. It does not mean it will leave the super globals 689 | ; array REQUEST empty. 690 | ; Default Value: None 691 | ; Development Value: "GP" 692 | ; Production Value: "GP" 693 | ; http://php.net/request-order 694 | request_order = "GP" 695 | 696 | ; Whether or not to register the EGPCS variables as global variables. You may 697 | ; want to turn this off if you don't want to clutter your scripts' global scope 698 | ; with user data. 699 | ; You should do your best to write your scripts so that they do not require 700 | ; register_globals to be on; Using form variables as globals can easily lead 701 | ; to possible security problems, if the code is not very well thought of. 702 | ; http://php.net/register-globals 703 | register_globals = Off 704 | 705 | ; Determines whether the deprecated long $HTTP_*_VARS type predefined variables 706 | ; are registered by PHP or not. As they are deprecated, we obviously don't 707 | ; recommend you use them. They are on by default for compatibility reasons but 708 | ; they are not recommended on production servers. 709 | ; Default Value: On 710 | ; Development Value: Off 711 | ; Production Value: Off 712 | ; http://php.net/register-long-arrays 713 | register_long_arrays = Off 714 | 715 | ; This directive determines whether PHP registers $argv & $argc each time it 716 | ; runs. $argv contains an array of all the arguments passed to PHP when a script 717 | ; is invoked. $argc contains an integer representing the number of arguments 718 | ; that were passed when the script was invoked. These arrays are extremely 719 | ; useful when running scripts from the command line. When this directive is 720 | ; enabled, registering these variables consumes CPU cycles and memory each time 721 | ; a script is executed. For performance reasons, this feature should be disabled 722 | ; on production servers. 723 | ; Note: This directive is hardcoded to On for the CLI SAPI 724 | ; Default Value: On 725 | ; Development Value: Off 726 | ; Production Value: Off 727 | ; http://php.net/register-argc-argv 728 | register_argc_argv = Off 729 | 730 | ; When enabled, the SERVER and ENV variables are created when they're first 731 | ; used (Just In Time) instead of when the script starts. If these variables 732 | ; are not used within a script, having this directive on will result in a 733 | ; performance gain. The PHP directives register_globals, register_long_arrays, 734 | ; and register_argc_argv must be disabled for this directive to have any affect. 735 | ; http://php.net/auto-globals-jit 736 | auto_globals_jit = On 737 | 738 | ; Maximum size of POST data that PHP will accept. 739 | ; http://php.net/post-max-size 740 | post_max_size = 500M 741 | 742 | ; Magic quotes are a preprocessing feature of PHP where PHP will attempt to 743 | ; escape any character sequences in GET, POST, COOKIE and ENV data which might 744 | ; otherwise corrupt data being placed in resources such as databases before 745 | ; making that data available to you. Because of character encoding issues and 746 | ; non-standard SQL implementations across many databases, it's not currently 747 | ; possible for this feature to be 100% accurate. PHP's default behavior is to 748 | ; enable the feature. We strongly recommend you use the escaping mechanisms 749 | ; designed specifically for the database your using instead of relying on this 750 | ; feature. Also note, this feature has been deprecated as of PHP 5.3.0 and is 751 | ; scheduled for removal in PHP 6. 752 | ; Default Value: On 753 | ; Development Value: Off 754 | ; Production Value: Off 755 | ; http://php.net/magic-quotes-gpc 756 | magic_quotes_gpc = Off 757 | 758 | ; Magic quotes for runtime-generated data, e.g. data from SQL, from exec(), etc. 759 | ; http://php.net/magic-quotes-runtime 760 | magic_quotes_runtime = Off 761 | 762 | ; Use Sybase-style magic quotes (escape ' with '' instead of \'). 763 | ; http://php.net/magic-quotes-sybase 764 | magic_quotes_sybase = Off 765 | 766 | ; Automatically add files before PHP document. 767 | ; http://php.net/auto-prepend-file 768 | auto_prepend_file = 769 | 770 | ; Automatically add files after PHP document. 771 | ; http://php.net/auto-append-file 772 | auto_append_file = 773 | 774 | ; By default, PHP will output a character encoding using 775 | ; the Content-type: header. To disable sending of the charset, simply 776 | ; set it to be empty. 777 | ; 778 | ; PHP's built-in default is text/html 779 | ; http://php.net/default-mimetype 780 | default_mimetype = "text/html" 781 | 782 | ; PHP's default character set is set to empty. 783 | ; http://php.net/default-charset 784 | ;default_charset = "iso-8859-1" 785 | 786 | ; Always populate the $HTTP_RAW_POST_DATA variable. PHP's default behavior is 787 | ; to disable this feature. 788 | ; http://php.net/always-populate-raw-post-data 789 | ;always_populate_raw_post_data = On 790 | 791 | ;;;;;;;;;;;;;;;;;;;;;;;;; 792 | ; Paths and Directories ; 793 | ;;;;;;;;;;;;;;;;;;;;;;;;; 794 | 795 | ; UNIX: "/path1:/path2" 796 | ;include_path = ".:/usr/share/php" 797 | ; 798 | ; Windows: "\path1;\path2" 799 | ;include_path = ".;c:\php\includes" 800 | ; 801 | ; PHP's default setting for include_path is ".;/path/to/php/pear" 802 | ; http://php.net/include-path 803 | 804 | ; The root of the PHP pages, used only if nonempty. 805 | ; if PHP was not compiled with FORCE_REDIRECT, you SHOULD set doc_root 806 | ; if you are running php as a CGI under any web server (other than IIS) 807 | ; see documentation for security issues. The alternate is to use the 808 | ; cgi.force_redirect configuration below 809 | ; http://php.net/doc-root 810 | doc_root = 811 | 812 | ; The directory under which PHP opens the script using /~username used only 813 | ; if nonempty. 814 | ; http://php.net/user-dir 815 | user_dir = 816 | 817 | ; Directory in which the loadable extensions (modules) reside. 818 | ; http://php.net/extension-dir 819 | ; extension_dir = "./" 820 | ; On windows: 821 | ; extension_dir = "ext" 822 | 823 | ; Whether or not to enable the dl() function. The dl() function does NOT work 824 | ; properly in multithreaded servers, such as IIS or Zeus, and is automatically 825 | ; disabled on them. 826 | ; http://php.net/enable-dl 827 | enable_dl = Off 828 | 829 | ; cgi.force_redirect is necessary to provide security running PHP as a CGI under 830 | ; most web servers. Left undefined, PHP turns this on by default. You can 831 | ; turn it off here AT YOUR OWN RISK 832 | ; **You CAN safely turn this off for IIS, in fact, you MUST.** 833 | ; http://php.net/cgi.force-redirect 834 | ;cgi.force_redirect = 1 835 | 836 | ; if cgi.nph is enabled it will force cgi to always sent Status: 200 with 837 | ; every request. PHP's default behavior is to disable this feature. 838 | ;cgi.nph = 1 839 | 840 | ; if cgi.force_redirect is turned on, and you are not running under Apache or Netscape 841 | ; (iPlanet) web servers, you MAY need to set an environment variable name that PHP 842 | ; will look for to know it is OK to continue execution. Setting this variable MAY 843 | ; cause security issues, KNOW WHAT YOU ARE DOING FIRST. 844 | ; http://php.net/cgi.redirect-status-env 845 | ;cgi.redirect_status_env = ; 846 | 847 | ; cgi.fix_pathinfo provides *real* PATH_INFO/PATH_TRANSLATED support for CGI. PHP's 848 | ; previous behaviour was to set PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok 849 | ; what PATH_INFO is. For more information on PATH_INFO, see the cgi specs. Setting 850 | ; this to 1 will cause PHP CGI to fix its paths to conform to the spec. A setting 851 | ; of zero causes PHP to behave as before. Default is 1. You should fix your scripts 852 | ; to use SCRIPT_FILENAME rather than PATH_TRANSLATED. 853 | ; http://php.net/cgi.fix-pathinfo 854 | ;cgi.fix_pathinfo=1 855 | 856 | ; FastCGI under IIS (on WINNT based OS) supports the ability to impersonate 857 | ; security tokens of the calling client. This allows IIS to define the 858 | ; security context that the request runs under. mod_fastcgi under Apache 859 | ; does not currently support this feature (03/17/2002) 860 | ; Set to 1 if running under IIS. Default is zero. 861 | ; http://php.net/fastcgi.impersonate 862 | ;fastcgi.impersonate = 1; 863 | 864 | ; Disable logging through FastCGI connection. PHP's default behavior is to enable 865 | ; this feature. 866 | ;fastcgi.logging = 0 867 | 868 | ; cgi.rfc2616_headers configuration option tells PHP what type of headers to 869 | ; use when sending HTTP response code. If it's set 0 PHP sends Status: header that 870 | ; is supported by Apache. When this option is set to 1 PHP will send 871 | ; RFC2616 compliant header. 872 | ; Default is zero. 873 | ; http://php.net/cgi.rfc2616-headers 874 | ;cgi.rfc2616_headers = 0 875 | 876 | ;;;;;;;;;;;;;;;; 877 | ; File Uploads ; 878 | ;;;;;;;;;;;;;;;; 879 | 880 | ; Whether to allow HTTP file uploads. 881 | ; http://php.net/file-uploads 882 | file_uploads = On 883 | 884 | ; Temporary directory for HTTP uploaded files (will use system default if not 885 | ; specified). 886 | ; http://php.net/upload-tmp-dir 887 | ;upload_tmp_dir = 888 | 889 | ; Maximum allowed size for uploaded files. 890 | ; http://php.net/upload-max-filesize 891 | upload_max_filesize = 500M 892 | 893 | ; Maximum number of files that can be uploaded via a single request 894 | max_file_uploads = 20 895 | 896 | ;;;;;;;;;;;;;;;;;; 897 | ; Fopen wrappers ; 898 | ;;;;;;;;;;;;;;;;;; 899 | 900 | ; Whether to allow the treatment of URLs (like http:// or ftp://) as files. 901 | ; http://php.net/allow-url-fopen 902 | allow_url_fopen = On 903 | 904 | ; Whether to allow include/require to open URLs (like http:// or ftp://) as files. 905 | ; http://php.net/allow-url-include 906 | allow_url_include = Off 907 | 908 | ; Define the anonymous ftp password (your email address). PHP's default setting 909 | ; for this is empty. 910 | ; http://php.net/from 911 | ;from="john@doe.com" 912 | 913 | ; Define the User-Agent string. PHP's default setting for this is empty. 914 | ; http://php.net/user-agent 915 | ;user_agent="PHP" 916 | 917 | ; Default timeout for socket based streams (seconds) 918 | ; http://php.net/default-socket-timeout 919 | default_socket_timeout = 60 920 | 921 | ; If your scripts have to deal with files from Macintosh systems, 922 | ; or you are running on a Mac and need to deal with files from 923 | ; unix or win32 systems, setting this flag will cause PHP to 924 | ; automatically detect the EOL character in those files so that 925 | ; fgets() and file() will work regardless of the source of the file. 926 | ; http://php.net/auto-detect-line-endings 927 | ;auto_detect_line_endings = Off 928 | 929 | ;;;;;;;;;;;;;;;;;;;;;; 930 | ; Dynamic Extensions ; 931 | ;;;;;;;;;;;;;;;;;;;;;; 932 | 933 | ; If you wish to have an extension loaded automatically, use the following 934 | ; syntax: 935 | ; 936 | ; extension=modulename.extension 937 | ; 938 | ; For example, on Windows: 939 | ; 940 | ; extension=msql.dll 941 | ; 942 | ; ... or under UNIX: 943 | ; 944 | ; extension=msql.so 945 | ; 946 | ; ... or with a path: 947 | ; 948 | ; extension=/path/to/extension/msql.so 949 | ; 950 | ; If you only provide the name of the extension, PHP will look for it in its 951 | ; default extension directory. 952 | 953 | ;;;;;;;;;;;;;;;;;;; 954 | ; Module Settings ; 955 | ;;;;;;;;;;;;;;;;;;; 956 | 957 | [Date] 958 | ; Defines the default timezone used by the date functions 959 | ; http://php.net/date.timezone 960 | ;date.timezone = 961 | 962 | ; http://php.net/date.default-latitude 963 | ;date.default_latitude = 31.7667 964 | 965 | ; http://php.net/date.default-longitude 966 | ;date.default_longitude = 35.2333 967 | 968 | ; http://php.net/date.sunrise-zenith 969 | ;date.sunrise_zenith = 90.583333 970 | 971 | ; http://php.net/date.sunset-zenith 972 | ;date.sunset_zenith = 90.583333 973 | 974 | [filter] 975 | ; http://php.net/filter.default 976 | ;filter.default = unsafe_raw 977 | 978 | ; http://php.net/filter.default-flags 979 | ;filter.default_flags = 980 | 981 | [iconv] 982 | ;iconv.input_encoding = ISO-8859-1 983 | ;iconv.internal_encoding = ISO-8859-1 984 | ;iconv.output_encoding = ISO-8859-1 985 | 986 | [intl] 987 | ;intl.default_locale = 988 | ; This directive allows you to produce PHP errors when some error 989 | ; happens within intl functions. The value is the level of the error produced. 990 | ; Default is 0, which does not produce any errors. 991 | ;intl.error_level = E_WARNING 992 | 993 | [sqlite] 994 | ; http://php.net/sqlite.assoc-case 995 | ;sqlite.assoc_case = 0 996 | 997 | [sqlite3] 998 | ;sqlite3.extension_dir = 999 | 1000 | [Pcre] 1001 | ;PCRE library backtracking limit. 1002 | ; http://php.net/pcre.backtrack-limit 1003 | ;pcre.backtrack_limit=100000 1004 | 1005 | ;PCRE library recursion limit. 1006 | ;Please note that if you set this value to a high number you may consume all 1007 | ;the available process stack and eventually crash PHP (due to reaching the 1008 | ;stack size limit imposed by the Operating System). 1009 | ; http://php.net/pcre.recursion-limit 1010 | ;pcre.recursion_limit=100000 1011 | 1012 | [Pdo] 1013 | ; Whether to pool ODBC connections. Can be one of "strict", "relaxed" or "off" 1014 | ; http://php.net/pdo-odbc.connection-pooling 1015 | ;pdo_odbc.connection_pooling=strict 1016 | 1017 | ;pdo_odbc.db2_instance_name 1018 | 1019 | [Pdo_mysql] 1020 | ; If mysqlnd is used: Number of cache slots for the internal result set cache 1021 | ; http://php.net/pdo_mysql.cache_size 1022 | pdo_mysql.cache_size = 2000 1023 | 1024 | ; Default socket name for local MySQL connects. If empty, uses the built-in 1025 | ; MySQL defaults. 1026 | ; http://php.net/pdo_mysql.default-socket 1027 | pdo_mysql.default_socket= 1028 | 1029 | [Phar] 1030 | ; http://php.net/phar.readonly 1031 | ;phar.readonly = On 1032 | 1033 | ; http://php.net/phar.require-hash 1034 | ;phar.require_hash = On 1035 | 1036 | ;phar.cache_list = 1037 | 1038 | [Syslog] 1039 | ; Whether or not to define the various syslog variables (e.g. $LOG_PID, 1040 | ; $LOG_CRON, etc.). Turning it off is a good idea performance-wise. In 1041 | ; runtime, you can define these variables by calling define_syslog_variables(). 1042 | ; http://php.net/define-syslog-variables 1043 | define_syslog_variables = Off 1044 | 1045 | [mail function] 1046 | ; For Win32 only. 1047 | ; http://php.net/smtp 1048 | SMTP = localhost 1049 | ; http://php.net/smtp-port 1050 | smtp_port = 25 1051 | 1052 | ; For Win32 only. 1053 | ; http://php.net/sendmail-from 1054 | ;sendmail_from = me@example.com 1055 | 1056 | ; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). 1057 | ; http://php.net/sendmail-path 1058 | ;sendmail_path =/usr/sbin/sendmail 1059 | sendmail_path = "/usr/bin/msmtp -t" 1060 | 1061 | ; Force the addition of the specified parameters to be passed as extra parameters 1062 | ; to the sendmail binary. These parameters will always replace the value of 1063 | ; the 5th parameter to mail(), even in safe mode. 1064 | ;mail.force_extra_parameters = 1065 | 1066 | ; Add X-PHP-Originating-Script: that will include uid of the script followed by the filename 1067 | mail.add_x_header = On 1068 | 1069 | ; The path to a log file that will log all mail() calls. Log entries include 1070 | ; the full path of the script, line number, To address and headers. 1071 | mail.log = /var/log/supervisor/sendmail.log 1072 | 1073 | [SQL] 1074 | ; http://php.net/sql.safe-mode 1075 | sql.safe_mode = Off 1076 | 1077 | [ODBC] 1078 | ; http://php.net/odbc.default-db 1079 | ;odbc.default_db = Not yet implemented 1080 | 1081 | ; http://php.net/odbc.default-user 1082 | ;odbc.default_user = Not yet implemented 1083 | 1084 | ; http://php.net/odbc.default-pw 1085 | ;odbc.default_pw = Not yet implemented 1086 | 1087 | ; Controls the ODBC cursor model. 1088 | ; Default: SQL_CURSOR_STATIC (default). 1089 | ;odbc.default_cursortype 1090 | 1091 | ; Allow or prevent persistent links. 1092 | ; http://php.net/odbc.allow-persistent 1093 | odbc.allow_persistent = On 1094 | 1095 | ; Check that a connection is still valid before reuse. 1096 | ; http://php.net/odbc.check-persistent 1097 | odbc.check_persistent = On 1098 | 1099 | ; Maximum number of persistent links. -1 means no limit. 1100 | ; http://php.net/odbc.max-persistent 1101 | odbc.max_persistent = -1 1102 | 1103 | ; Maximum number of links (persistent + non-persistent). -1 means no limit. 1104 | ; http://php.net/odbc.max-links 1105 | odbc.max_links = -1 1106 | 1107 | ; Handling of LONG fields. Returns number of bytes to variables. 0 means 1108 | ; passthru. 1109 | ; http://php.net/odbc.defaultlrl 1110 | odbc.defaultlrl = 4096 1111 | 1112 | ; Handling of binary data. 0 means passthru, 1 return as is, 2 convert to char. 1113 | ; See the documentation on odbc_binmode and odbc_longreadlen for an explanation 1114 | ; of odbc.defaultlrl and odbc.defaultbinmode 1115 | ; http://php.net/odbc.defaultbinmode 1116 | odbc.defaultbinmode = 1 1117 | 1118 | ;birdstep.max_links = -1 1119 | 1120 | [Interbase] 1121 | ; Allow or prevent persistent links. 1122 | ibase.allow_persistent = 1 1123 | 1124 | ; Maximum number of persistent links. -1 means no limit. 1125 | ibase.max_persistent = -1 1126 | 1127 | ; Maximum number of links (persistent + non-persistent). -1 means no limit. 1128 | ibase.max_links = -1 1129 | 1130 | ; Default database name for ibase_connect(). 1131 | ;ibase.default_db = 1132 | 1133 | ; Default username for ibase_connect(). 1134 | ;ibase.default_user = 1135 | 1136 | ; Default password for ibase_connect(). 1137 | ;ibase.default_password = 1138 | 1139 | ; Default charset for ibase_connect(). 1140 | ;ibase.default_charset = 1141 | 1142 | ; Default timestamp format. 1143 | ibase.timestampformat = "%Y-%m-%d %H:%M:%S" 1144 | 1145 | ; Default date format. 1146 | ibase.dateformat = "%Y-%m-%d" 1147 | 1148 | ; Default time format. 1149 | ibase.timeformat = "%H:%M:%S" 1150 | 1151 | [MySQL] 1152 | ; Allow accessing, from PHP's perspective, local files with LOAD DATA statements 1153 | ; http://php.net/mysql.allow_local_infile 1154 | mysql.allow_local_infile = On 1155 | 1156 | ; Allow or prevent persistent links. 1157 | ; http://php.net/mysql.allow-persistent 1158 | mysql.allow_persistent = On 1159 | 1160 | ; If mysqlnd is used: Number of cache slots for the internal result set cache 1161 | ; http://php.net/mysql.cache_size 1162 | mysql.cache_size = 2000 1163 | 1164 | ; Maximum number of persistent links. -1 means no limit. 1165 | ; http://php.net/mysql.max-persistent 1166 | mysql.max_persistent = -1 1167 | 1168 | ; Maximum number of links (persistent + non-persistent). -1 means no limit. 1169 | ; http://php.net/mysql.max-links 1170 | mysql.max_links = -1 1171 | 1172 | ; Default port number for mysql_connect(). If unset, mysql_connect() will use 1173 | ; the $MYSQL_TCP_PORT or the mysql-tcp entry in /etc/services or the 1174 | ; compile-time value defined MYSQL_PORT (in that order). Win32 will only look 1175 | ; at MYSQL_PORT. 1176 | ; http://php.net/mysql.default-port 1177 | mysql.default_port = 1178 | 1179 | ; Default socket name for local MySQL connects. If empty, uses the built-in 1180 | ; MySQL defaults. 1181 | ; http://php.net/mysql.default-socket 1182 | mysql.default_socket = 1183 | 1184 | ; Default host for mysql_connect() (doesn't apply in safe mode). 1185 | ; http://php.net/mysql.default-host 1186 | mysql.default_host = 1187 | 1188 | ; Default user for mysql_connect() (doesn't apply in safe mode). 1189 | ; http://php.net/mysql.default-user 1190 | mysql.default_user = 1191 | 1192 | ; Default password for mysql_connect() (doesn't apply in safe mode). 1193 | ; Note that this is generally a *bad* idea to store passwords in this file. 1194 | ; *Any* user with PHP access can run 'echo get_cfg_var("mysql.default_password") 1195 | ; and reveal this password! And of course, any users with read access to this 1196 | ; file will be able to reveal the password as well. 1197 | ; http://php.net/mysql.default-password 1198 | mysql.default_password = 1199 | 1200 | ; Maximum time (in seconds) for connect timeout. -1 means no limit 1201 | ; http://php.net/mysql.connect-timeout 1202 | mysql.connect_timeout = 60 1203 | 1204 | ; Trace mode. When trace_mode is active (=On), warnings for table/index scans and 1205 | ; SQL-Errors will be displayed. 1206 | ; http://php.net/mysql.trace-mode 1207 | mysql.trace_mode = Off 1208 | 1209 | [MySQLi] 1210 | 1211 | ; Maximum number of persistent links. -1 means no limit. 1212 | ; http://php.net/mysqli.max-persistent 1213 | mysqli.max_persistent = -1 1214 | 1215 | ; Allow accessing, from PHP's perspective, local files with LOAD DATA statements 1216 | ; http://php.net/mysqli.allow_local_infile 1217 | ;mysqli.allow_local_infile = On 1218 | 1219 | ; Allow or prevent persistent links. 1220 | ; http://php.net/mysqli.allow-persistent 1221 | mysqli.allow_persistent = On 1222 | 1223 | ; Maximum number of links. -1 means no limit. 1224 | ; http://php.net/mysqli.max-links 1225 | mysqli.max_links = -1 1226 | 1227 | ; If mysqlnd is used: Number of cache slots for the internal result set cache 1228 | ; http://php.net/mysqli.cache_size 1229 | mysqli.cache_size = 2000 1230 | 1231 | ; Default port number for mysqli_connect(). If unset, mysqli_connect() will use 1232 | ; the $MYSQL_TCP_PORT or the mysql-tcp entry in /etc/services or the 1233 | ; compile-time value defined MYSQL_PORT (in that order). Win32 will only look 1234 | ; at MYSQL_PORT. 1235 | ; http://php.net/mysqli.default-port 1236 | mysqli.default_port = 3306 1237 | 1238 | ; Default socket name for local MySQL connects. If empty, uses the built-in 1239 | ; MySQL defaults. 1240 | ; http://php.net/mysqli.default-socket 1241 | mysqli.default_socket = 1242 | 1243 | ; Default host for mysql_connect() (doesn't apply in safe mode). 1244 | ; http://php.net/mysqli.default-host 1245 | mysqli.default_host = 1246 | 1247 | ; Default user for mysql_connect() (doesn't apply in safe mode). 1248 | ; http://php.net/mysqli.default-user 1249 | mysqli.default_user = 1250 | 1251 | ; Default password for mysqli_connect() (doesn't apply in safe mode). 1252 | ; Note that this is generally a *bad* idea to store passwords in this file. 1253 | ; *Any* user with PHP access can run 'echo get_cfg_var("mysqli.default_pw") 1254 | ; and reveal this password! And of course, any users with read access to this 1255 | ; file will be able to reveal the password as well. 1256 | ; http://php.net/mysqli.default-pw 1257 | mysqli.default_pw = 1258 | 1259 | ; Allow or prevent reconnect 1260 | mysqli.reconnect = Off 1261 | 1262 | [mysqlnd] 1263 | ; Enable / Disable collection of general statistics by mysqlnd which can be 1264 | ; used to tune and monitor MySQL operations. 1265 | ; http://php.net/mysqlnd.collect_statistics 1266 | mysqlnd.collect_statistics = On 1267 | 1268 | ; Enable / Disable collection of memory usage statistics by mysqlnd which can be 1269 | ; used to tune and monitor MySQL operations. 1270 | ; http://php.net/mysqlnd.collect_memory_statistics 1271 | mysqlnd.collect_memory_statistics = Off 1272 | 1273 | ; Size of a pre-allocated buffer used when sending commands to MySQL in bytes. 1274 | ; http://php.net/mysqlnd.net_cmd_buffer_size 1275 | ;mysqlnd.net_cmd_buffer_size = 2048 1276 | 1277 | ; Size of a pre-allocated buffer used for reading data sent by the server in 1278 | ; bytes. 1279 | ; http://php.net/mysqlnd.net_read_buffer_size 1280 | ;mysqlnd.net_read_buffer_size = 32768 1281 | 1282 | [OCI8] 1283 | 1284 | ; Connection: Enables privileged connections using external 1285 | ; credentials (OCI_SYSOPER, OCI_SYSDBA) 1286 | ; http://php.net/oci8.privileged-connect 1287 | ;oci8.privileged_connect = Off 1288 | 1289 | ; Connection: The maximum number of persistent OCI8 connections per 1290 | ; process. Using -1 means no limit. 1291 | ; http://php.net/oci8.max-persistent 1292 | ;oci8.max_persistent = -1 1293 | 1294 | ; Connection: The maximum number of seconds a process is allowed to 1295 | ; maintain an idle persistent connection. Using -1 means idle 1296 | ; persistent connections will be maintained forever. 1297 | ; http://php.net/oci8.persistent-timeout 1298 | ;oci8.persistent_timeout = -1 1299 | 1300 | ; Connection: The number of seconds that must pass before issuing a 1301 | ; ping during oci_pconnect() to check the connection validity. When 1302 | ; set to 0, each oci_pconnect() will cause a ping. Using -1 disables 1303 | ; pings completely. 1304 | ; http://php.net/oci8.ping-interval 1305 | ;oci8.ping_interval = 60 1306 | 1307 | ; Connection: Set this to a user chosen connection class to be used 1308 | ; for all pooled server requests with Oracle 11g Database Resident 1309 | ; Connection Pooling (DRCP). To use DRCP, this value should be set to 1310 | ; the same string for all web servers running the same application, 1311 | ; the database pool must be configured, and the connection string must 1312 | ; specify to use a pooled server. 1313 | ;oci8.connection_class = 1314 | 1315 | ; High Availability: Using On lets PHP receive Fast Application 1316 | ; Notification (FAN) events generated when a database node fails. The 1317 | ; database must also be configured to post FAN events. 1318 | ;oci8.events = Off 1319 | 1320 | ; Tuning: This option enables statement caching, and specifies how 1321 | ; many statements to cache. Using 0 disables statement caching. 1322 | ; http://php.net/oci8.statement-cache-size 1323 | ;oci8.statement_cache_size = 20 1324 | 1325 | ; Tuning: Enables statement prefetching and sets the default number of 1326 | ; rows that will be fetched automatically after statement execution. 1327 | ; http://php.net/oci8.default-prefetch 1328 | ;oci8.default_prefetch = 100 1329 | 1330 | ; Compatibility. Using On means oci_close() will not close 1331 | ; oci_connect() and oci_new_connect() connections. 1332 | ; http://php.net/oci8.old-oci-close-semantics 1333 | ;oci8.old_oci_close_semantics = Off 1334 | 1335 | [PostgreSQL] 1336 | ; Allow or prevent persistent links. 1337 | ; http://php.net/pgsql.allow-persistent 1338 | pgsql.allow_persistent = On 1339 | 1340 | ; Detect broken persistent links always with pg_pconnect(). 1341 | ; Auto reset feature requires a little overheads. 1342 | ; http://php.net/pgsql.auto-reset-persistent 1343 | pgsql.auto_reset_persistent = Off 1344 | 1345 | ; Maximum number of persistent links. -1 means no limit. 1346 | ; http://php.net/pgsql.max-persistent 1347 | pgsql.max_persistent = -1 1348 | 1349 | ; Maximum number of links (persistent+non persistent). -1 means no limit. 1350 | ; http://php.net/pgsql.max-links 1351 | pgsql.max_links = -1 1352 | 1353 | ; Ignore PostgreSQL backends Notice message or not. 1354 | ; Notice message logging require a little overheads. 1355 | ; http://php.net/pgsql.ignore-notice 1356 | pgsql.ignore_notice = 0 1357 | 1358 | ; Log PostgreSQL backends Notice message or not. 1359 | ; Unless pgsql.ignore_notice=0, module cannot log notice message. 1360 | ; http://php.net/pgsql.log-notice 1361 | pgsql.log_notice = 0 1362 | 1363 | [Sybase-CT] 1364 | ; Allow or prevent persistent links. 1365 | ; http://php.net/sybct.allow-persistent 1366 | sybct.allow_persistent = On 1367 | 1368 | ; Maximum number of persistent links. -1 means no limit. 1369 | ; http://php.net/sybct.max-persistent 1370 | sybct.max_persistent = -1 1371 | 1372 | ; Maximum number of links (persistent + non-persistent). -1 means no limit. 1373 | ; http://php.net/sybct.max-links 1374 | sybct.max_links = -1 1375 | 1376 | ; Minimum server message severity to display. 1377 | ; http://php.net/sybct.min-server-severity 1378 | sybct.min_server_severity = 10 1379 | 1380 | ; Minimum client message severity to display. 1381 | ; http://php.net/sybct.min-client-severity 1382 | sybct.min_client_severity = 10 1383 | 1384 | ; Set per-context timeout 1385 | ; http://php.net/sybct.timeout 1386 | ;sybct.timeout= 1387 | 1388 | ;sybct.packet_size 1389 | 1390 | ; The maximum time in seconds to wait for a connection attempt to succeed before returning failure. 1391 | ; Default: one minute 1392 | ;sybct.login_timeout= 1393 | 1394 | ; The name of the host you claim to be connecting from, for display by sp_who. 1395 | ; Default: none 1396 | ;sybct.hostname= 1397 | 1398 | ; Allows you to define how often deadlocks are to be retried. -1 means "forever". 1399 | ; Default: 0 1400 | ;sybct.deadlock_retry_count= 1401 | 1402 | [bcmath] 1403 | ; Number of decimal digits for all bcmath functions. 1404 | ; http://php.net/bcmath.scale 1405 | bcmath.scale = 0 1406 | 1407 | [browscap] 1408 | ; http://php.net/browscap 1409 | ;browscap = extra/browscap.ini 1410 | 1411 | [Session] 1412 | ; Handler used to store/retrieve data. 1413 | ; http://php.net/session.save-handler 1414 | session.save_handler = files 1415 | 1416 | ; Argument passed to save_handler. In the case of files, this is the path 1417 | ; where data files are stored. Note: Windows users have to change this 1418 | ; variable in order to use PHP's session functions. 1419 | ; 1420 | ; The path can be defined as: 1421 | ; 1422 | ; session.save_path = "N;/path" 1423 | ; 1424 | ; where N is an integer. Instead of storing all the session files in 1425 | ; /path, what this will do is use subdirectories N-levels deep, and 1426 | ; store the session data in those directories. This is useful if you 1427 | ; or your OS have problems with lots of files in one directory, and is 1428 | ; a more efficient layout for servers that handle lots of sessions. 1429 | ; 1430 | ; NOTE 1: PHP will not create this directory structure automatically. 1431 | ; You can use the script in the ext/session dir for that purpose. 1432 | ; NOTE 2: See the section on garbage collection below if you choose to 1433 | ; use subdirectories for session storage 1434 | ; 1435 | ; The file storage module creates files using mode 600 by default. 1436 | ; You can change that by using 1437 | ; 1438 | ; session.save_path = "N;MODE;/path" 1439 | ; 1440 | ; where MODE is the octal representation of the mode. Note that this 1441 | ; does not overwrite the process's umask. 1442 | ; http://php.net/session.save-path 1443 | ;session.save_path = "/tmp" 1444 | 1445 | ; Whether to use cookies. 1446 | ; http://php.net/session.use-cookies 1447 | session.use_cookies = 1 1448 | 1449 | ; http://php.net/session.cookie-secure 1450 | ;session.cookie_secure = 1451 | 1452 | ; This option forces PHP to fetch and use a cookie for storing and maintaining 1453 | ; the session id. We encourage this operation as it's very helpful in combatting 1454 | ; session hijacking when not specifying and managing your own session id. It is 1455 | ; not the end all be all of session hijacking defense, but it's a good start. 1456 | ; http://php.net/session.use-only-cookies 1457 | session.use_only_cookies = 1 1458 | 1459 | ; Name of the session (used as cookie name). 1460 | ; http://php.net/session.name 1461 | session.name = PHPSESSID 1462 | 1463 | ; Initialize session on request startup. 1464 | ; http://php.net/session.auto-start 1465 | session.auto_start = 0 1466 | 1467 | ; Lifetime in seconds of cookie or, if 0, until browser is restarted. 1468 | ; http://php.net/session.cookie-lifetime 1469 | session.cookie_lifetime = 0 1470 | 1471 | ; The path for which the cookie is valid. 1472 | ; http://php.net/session.cookie-path 1473 | session.cookie_path = / 1474 | 1475 | ; The domain for which the cookie is valid. 1476 | ; http://php.net/session.cookie-domain 1477 | session.cookie_domain = 1478 | 1479 | ; Whether or not to add the httpOnly flag to the cookie, which makes it inaccessible to browser scripting languages such as JavaScript. 1480 | ; http://php.net/session.cookie-httponly 1481 | session.cookie_httponly = 1482 | 1483 | ; Handler used to serialize data. php is the standard serializer of PHP. 1484 | ; http://php.net/session.serialize-handler 1485 | session.serialize_handler = php 1486 | 1487 | ; Defines the probability that the 'garbage collection' process is started 1488 | ; on every session initialization. The probability is calculated by using 1489 | ; gc_probability/gc_divisor. Where session.gc_probability is the numerator 1490 | ; and gc_divisor is the denominator in the equation. Setting this value to 1 1491 | ; when the session.gc_divisor value is 100 will give you approximately a 1% chance 1492 | ; the gc will run on any give request. 1493 | ; Default Value: 1 1494 | ; Development Value: 1 1495 | ; Production Value: 1 1496 | ; http://php.net/session.gc-probability 1497 | session.gc_probability = 0 1498 | 1499 | ; Defines the probability that the 'garbage collection' process is started on every 1500 | ; session initialization. The probability is calculated by using the following equation: 1501 | ; gc_probability/gc_divisor. Where session.gc_probability is the numerator and 1502 | ; session.gc_divisor is the denominator in the equation. Setting this value to 1 1503 | ; when the session.gc_divisor value is 100 will give you approximately a 1% chance 1504 | ; the gc will run on any give request. Increasing this value to 1000 will give you 1505 | ; a 0.1% chance the gc will run on any give request. For high volume production servers, 1506 | ; this is a more efficient approach. 1507 | ; Default Value: 100 1508 | ; Development Value: 1000 1509 | ; Production Value: 1000 1510 | ; http://php.net/session.gc-divisor 1511 | session.gc_divisor = 1000 1512 | 1513 | ; After this number of seconds, stored data will be seen as 'garbage' and 1514 | ; cleaned up by the garbage collection process. 1515 | ; http://php.net/session.gc-maxlifetime 1516 | session.gc_maxlifetime = 1440 1517 | 1518 | ; NOTE: If you are using the subdirectory option for storing session files 1519 | ; (see session.save_path above), then garbage collection does *not* 1520 | ; happen automatically. You will need to do your own garbage 1521 | ; collection through a shell script, cron entry, or some other method. 1522 | ; For example, the following script would is the equivalent of 1523 | ; setting session.gc_maxlifetime to 1440 (1440 seconds = 24 minutes): 1524 | ; find /path/to/sessions -cmin +24 | xargs rm 1525 | 1526 | ; PHP 4.2 and less have an undocumented feature/bug that allows you to 1527 | ; to initialize a session variable in the global scope, even when register_globals 1528 | ; is disabled. PHP 4.3 and later will warn you, if this feature is used. 1529 | ; You can disable the feature and the warning separately. At this time, 1530 | ; the warning is only displayed, if bug_compat_42 is enabled. This feature 1531 | ; introduces some serious security problems if not handled correctly. It's 1532 | ; recommended that you do not use this feature on production servers. But you 1533 | ; should enable this on development servers and enable the warning as well. If you 1534 | ; do not enable the feature on development servers, you won't be warned when it's 1535 | ; used and debugging errors caused by this can be difficult to track down. 1536 | ; Default Value: On 1537 | ; Development Value: On 1538 | ; Production Value: Off 1539 | ; http://php.net/session.bug-compat-42 1540 | session.bug_compat_42 = Off 1541 | 1542 | ; This setting controls whether or not you are warned by PHP when initializing a 1543 | ; session value into the global space. session.bug_compat_42 must be enabled before 1544 | ; these warnings can be issued by PHP. See the directive above for more information. 1545 | ; Default Value: On 1546 | ; Development Value: On 1547 | ; Production Value: Off 1548 | ; http://php.net/session.bug-compat-warn 1549 | session.bug_compat_warn = Off 1550 | 1551 | ; Check HTTP Referer to invalidate externally stored URLs containing ids. 1552 | ; HTTP_REFERER has to contain this substring for the session to be 1553 | ; considered as valid. 1554 | ; http://php.net/session.referer-check 1555 | session.referer_check = 1556 | 1557 | ; How many bytes to read from the file. 1558 | ; http://php.net/session.entropy-length 1559 | session.entropy_length = 0 1560 | 1561 | ; Specified here to create the session id. 1562 | ; http://php.net/session.entropy-file 1563 | ; On systems that don't have /dev/urandom /dev/arandom can be used 1564 | ; On windows, setting the entropy_length setting will activate the 1565 | ; Windows random source (using the CryptoAPI) 1566 | ;session.entropy_file = /dev/urandom 1567 | 1568 | ; Set to {nocache,private,public,} to determine HTTP caching aspects 1569 | ; or leave this empty to avoid sending anti-caching headers. 1570 | ; http://php.net/session.cache-limiter 1571 | session.cache_limiter = nocache 1572 | 1573 | ; Document expires after n minutes. 1574 | ; http://php.net/session.cache-expire 1575 | session.cache_expire = 180 1576 | 1577 | ; trans sid support is disabled by default. 1578 | ; Use of trans sid may risk your users security. 1579 | ; Use this option with caution. 1580 | ; - User may send URL contains active session ID 1581 | ; to other person via. email/irc/etc. 1582 | ; - URL that contains active session ID may be stored 1583 | ; in publically accessible computer. 1584 | ; - User may access your site with the same session ID 1585 | ; always using URL stored in browser's history or bookmarks. 1586 | ; http://php.net/session.use-trans-sid 1587 | session.use_trans_sid = 0 1588 | 1589 | ; Select a hash function for use in generating session ids. 1590 | ; Possible Values 1591 | ; 0 (MD5 128 bits) 1592 | ; 1 (SHA-1 160 bits) 1593 | ; This option may also be set to the name of any hash function supported by 1594 | ; the hash extension. A list of available hashes is returned by the hash_algos() 1595 | ; function. 1596 | ; http://php.net/session.hash-function 1597 | session.hash_function = 0 1598 | 1599 | ; Define how many bits are stored in each character when converting 1600 | ; the binary hash data to something readable. 1601 | ; Possible values: 1602 | ; 4 (4 bits: 0-9, a-f) 1603 | ; 5 (5 bits: 0-9, a-v) 1604 | ; 6 (6 bits: 0-9, a-z, A-Z, "-", ",") 1605 | ; Default Value: 4 1606 | ; Development Value: 5 1607 | ; Production Value: 5 1608 | ; http://php.net/session.hash-bits-per-character 1609 | session.hash_bits_per_character = 5 1610 | 1611 | ; The URL rewriter will look for URLs in a defined set of HTML tags. 1612 | ; form/fieldset are special; if you include them here, the rewriter will 1613 | ; add a hidden field with the info which is otherwise appended 1614 | ; to URLs. If you want XHTML conformity, remove the form entry. 1615 | ; Note that all valid entries require a "=", even if no value follows. 1616 | ; Default Value: "a=href,area=href,frame=src,form=,fieldset=" 1617 | ; Development Value: "a=href,area=href,frame=src,input=src,form=fakeentry" 1618 | ; Production Value: "a=href,area=href,frame=src,input=src,form=fakeentry" 1619 | ; http://php.net/url-rewriter.tags 1620 | url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=fakeentry" 1621 | 1622 | [MSSQL] 1623 | ; Allow or prevent persistent links. 1624 | mssql.allow_persistent = On 1625 | 1626 | ; Maximum number of persistent links. -1 means no limit. 1627 | mssql.max_persistent = -1 1628 | 1629 | ; Maximum number of links (persistent+non persistent). -1 means no limit. 1630 | mssql.max_links = -1 1631 | 1632 | ; Minimum error severity to display. 1633 | mssql.min_error_severity = 10 1634 | 1635 | ; Minimum message severity to display. 1636 | mssql.min_message_severity = 10 1637 | 1638 | ; Compatibility mode with old versions of PHP 3.0. 1639 | mssql.compatability_mode = Off 1640 | 1641 | ; Connect timeout 1642 | ;mssql.connect_timeout = 5 1643 | 1644 | ; Query timeout 1645 | ;mssql.timeout = 60 1646 | 1647 | ; Valid range 0 - 2147483647. Default = 4096. 1648 | ;mssql.textlimit = 4096 1649 | 1650 | ; Valid range 0 - 2147483647. Default = 4096. 1651 | ;mssql.textsize = 4096 1652 | 1653 | ; Limits the number of records in each batch. 0 = all records in one batch. 1654 | ;mssql.batchsize = 0 1655 | 1656 | ; Specify how datetime and datetim4 columns are returned 1657 | ; On => Returns data converted to SQL server settings 1658 | ; Off => Returns values as YYYY-MM-DD hh:mm:ss 1659 | ;mssql.datetimeconvert = On 1660 | 1661 | ; Use NT authentication when connecting to the server 1662 | mssql.secure_connection = Off 1663 | 1664 | ; Specify max number of processes. -1 = library default 1665 | ; msdlib defaults to 25 1666 | ; FreeTDS defaults to 4096 1667 | ;mssql.max_procs = -1 1668 | 1669 | ; Specify client character set. 1670 | ; If empty or not set the client charset from freetds.conf is used 1671 | ; This is only used when compiled with FreeTDS 1672 | ;mssql.charset = "ISO-8859-1" 1673 | 1674 | [Assertion] 1675 | ; Assert(expr); active by default. 1676 | ; http://php.net/assert.active 1677 | ;assert.active = On 1678 | 1679 | ; Issue a PHP warning for each failed assertion. 1680 | ; http://php.net/assert.warning 1681 | ;assert.warning = On 1682 | 1683 | ; Don't bail out by default. 1684 | ; http://php.net/assert.bail 1685 | ;assert.bail = Off 1686 | 1687 | ; User-function to be called if an assertion fails. 1688 | ; http://php.net/assert.callback 1689 | ;assert.callback = 0 1690 | 1691 | ; Eval the expression with current error_reporting(). Set to true if you want 1692 | ; error_reporting(0) around the eval(). 1693 | ; http://php.net/assert.quiet-eval 1694 | ;assert.quiet_eval = 0 1695 | 1696 | [COM] 1697 | ; path to a file containing GUIDs, IIDs or filenames of files with TypeLibs 1698 | ; http://php.net/com.typelib-file 1699 | ;com.typelib_file = 1700 | 1701 | ; allow Distributed-COM calls 1702 | ; http://php.net/com.allow-dcom 1703 | ;com.allow_dcom = true 1704 | 1705 | ; autoregister constants of a components typlib on com_load() 1706 | ; http://php.net/com.autoregister-typelib 1707 | ;com.autoregister_typelib = true 1708 | 1709 | ; register constants casesensitive 1710 | ; http://php.net/com.autoregister-casesensitive 1711 | ;com.autoregister_casesensitive = false 1712 | 1713 | ; show warnings on duplicate constant registrations 1714 | ; http://php.net/com.autoregister-verbose 1715 | ;com.autoregister_verbose = true 1716 | 1717 | ; The default character set code-page to use when passing strings to and from COM objects. 1718 | ; Default: system ANSI code page 1719 | ;com.code_page= 1720 | 1721 | [mbstring] 1722 | ; language for internal character representation. 1723 | ; http://php.net/mbstring.language 1724 | ;mbstring.language = Japanese 1725 | 1726 | ; internal/script encoding. 1727 | ; Some encoding cannot work as internal encoding. 1728 | ; (e.g. SJIS, BIG5, ISO-2022-*) 1729 | ; http://php.net/mbstring.internal-encoding 1730 | ;mbstring.internal_encoding = EUC-JP 1731 | 1732 | ; http input encoding. 1733 | ; http://php.net/mbstring.http-input 1734 | ;mbstring.http_input = auto 1735 | 1736 | ; http output encoding. mb_output_handler must be 1737 | ; registered as output buffer to function 1738 | ; http://php.net/mbstring.http-output 1739 | ;mbstring.http_output = SJIS 1740 | 1741 | ; enable automatic encoding translation according to 1742 | ; mbstring.internal_encoding setting. Input chars are 1743 | ; converted to internal encoding by setting this to On. 1744 | ; Note: Do _not_ use automatic encoding translation for 1745 | ; portable libs/applications. 1746 | ; http://php.net/mbstring.encoding-translation 1747 | ;mbstring.encoding_translation = Off 1748 | 1749 | ; automatic encoding detection order. 1750 | ; auto means 1751 | ; http://php.net/mbstring.detect-order 1752 | ;mbstring.detect_order = auto 1753 | 1754 | ; substitute_character used when character cannot be converted 1755 | ; one from another 1756 | ; http://php.net/mbstring.substitute-character 1757 | ;mbstring.substitute_character = none; 1758 | 1759 | ; overload(replace) single byte functions by mbstring functions. 1760 | ; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(), 1761 | ; etc. Possible values are 0,1,2,4 or combination of them. 1762 | ; For example, 7 for overload everything. 1763 | ; 0: No overload 1764 | ; 1: Overload mail() function 1765 | ; 2: Overload str*() functions 1766 | ; 4: Overload ereg*() functions 1767 | ; http://php.net/mbstring.func-overload 1768 | ;mbstring.func_overload = 0 1769 | 1770 | ; enable strict encoding detection. 1771 | ;mbstring.strict_detection = Off 1772 | 1773 | ; This directive specifies the regex pattern of content types for which mb_output_handler() 1774 | ; is activated. 1775 | ; Default: mbstring.http_output_conv_mimetype=^(text/|application/xhtml\+xml) 1776 | ;mbstring.http_output_conv_mimetype= 1777 | 1778 | ; Allows to set script encoding. Only affects if PHP is compiled with --enable-zend-multibyte 1779 | ; Default: "" 1780 | ;mbstring.script_encoding= 1781 | 1782 | [gd] 1783 | ; Tell the jpeg decode to ignore warnings and try to create 1784 | ; a gd image. The warning will then be displayed as notices 1785 | ; disabled by default 1786 | ; http://php.net/gd.jpeg-ignore-warning 1787 | ;gd.jpeg_ignore_warning = 0 1788 | 1789 | [exif] 1790 | ; Exif UNICODE user comments are handled as UCS-2BE/UCS-2LE and JIS as JIS. 1791 | ; With mbstring support this will automatically be converted into the encoding 1792 | ; given by corresponding encode setting. When empty mbstring.internal_encoding 1793 | ; is used. For the decode settings you can distinguish between motorola and 1794 | ; intel byte order. A decode setting cannot be empty. 1795 | ; http://php.net/exif.encode-unicode 1796 | ;exif.encode_unicode = ISO-8859-15 1797 | 1798 | ; http://php.net/exif.decode-unicode-motorola 1799 | ;exif.decode_unicode_motorola = UCS-2BE 1800 | 1801 | ; http://php.net/exif.decode-unicode-intel 1802 | ;exif.decode_unicode_intel = UCS-2LE 1803 | 1804 | ; http://php.net/exif.encode-jis 1805 | ;exif.encode_jis = 1806 | 1807 | ; http://php.net/exif.decode-jis-motorola 1808 | ;exif.decode_jis_motorola = JIS 1809 | 1810 | ; http://php.net/exif.decode-jis-intel 1811 | ;exif.decode_jis_intel = JIS 1812 | 1813 | [Tidy] 1814 | ; The path to a default tidy configuration file to use when using tidy 1815 | ; http://php.net/tidy.default-config 1816 | ;tidy.default_config = /usr/local/lib/php/default.tcfg 1817 | 1818 | ; Should tidy clean and repair output automatically? 1819 | ; WARNING: Do not use this option if you are generating non-html content 1820 | ; such as dynamic images 1821 | ; http://php.net/tidy.clean-output 1822 | tidy.clean_output = Off 1823 | 1824 | [soap] 1825 | ; Enables or disables WSDL caching feature. 1826 | ; http://php.net/soap.wsdl-cache-enabled 1827 | soap.wsdl_cache_enabled=1 1828 | 1829 | ; Sets the directory name where SOAP extension will put cache files. 1830 | ; http://php.net/soap.wsdl-cache-dir 1831 | soap.wsdl_cache_dir="/tmp" 1832 | 1833 | ; (time to live) Sets the number of second while cached file will be used 1834 | ; instead of original one. 1835 | ; http://php.net/soap.wsdl-cache-ttl 1836 | soap.wsdl_cache_ttl=86400 1837 | 1838 | ; Sets the size of the cache limit. (Max. number of WSDL files to cache) 1839 | soap.wsdl_cache_limit = 5 1840 | 1841 | [sysvshm] 1842 | ; A default size of the shared memory segment 1843 | ;sysvshm.init_mem = 10000 1844 | 1845 | [ldap] 1846 | ; Sets the maximum number of open links or -1 for unlimited. 1847 | ldap.max_links = -1 1848 | 1849 | [mcrypt] 1850 | ; For more information about mcrypt settings see http://php.net/mcrypt-module-open 1851 | 1852 | ; Directory where to load mcrypt algorithms 1853 | ; Default: Compiled in into libmcrypt (usually /usr/local/lib/libmcrypt) 1854 | ;mcrypt.algorithms_dir= 1855 | 1856 | ; Directory where to load mcrypt modes 1857 | ; Default: Compiled in into libmcrypt (usually /usr/local/lib/libmcrypt) 1858 | ;mcrypt.modes_dir= 1859 | 1860 | [dba] 1861 | ;dba.default_handler= 1862 | 1863 | [xsl] 1864 | ; Write operations from within XSLT are disabled by default. 1865 | ; XSL_SECPREF_CREATE_DIRECTORY | XSL_SECPREF_WRITE_NETWORK | XSL_SECPREF_WRITE_FILE = 44 1866 | ; Set it to 0 to allow all operations 1867 | ;xsl.security_prefs = 44 1868 | 1869 | ; Local Variables: 1870 | ; tab-width: 4 1871 | ; End: 1872 | --------------------------------------------------------------------------------