记录自己的php.ini、php-fpm.conf和nginx.conf配置文件
记下自己的php.ini和php-fpm.conf配置,方便下次使用。
php.ini
error_reporting = E_ALL display_errors = On display_startup_errors = On track_errors = On session.save_path = "/app/php5/var/tmp" session.bug_compat_42 = On session.bug_compat_warn = On date.default_latitude = 31.7667 date.default_longitude = 35.2333 date.sunrise_zenith = 90.583333 date.sunset_zenith = 90.583333 mysqlnd.collect_memory_statistics = On [xdebug] zend_extension=/WorkSpace/app/php5/lib/php/extensions/no-debug-non-zts-20100525/xdebug.so xdebug.file_link_format = "txmt://open?url=file://%f&line=%l" xdebug.profiler_enable=1 xdebug.profiler_enable_trigger=1 xdebug.profiler_output_dir=/tmp/xdebug/ [xcache-common] zend_extension=/app/php5/lib/php/extensions/no-debug-non-zts-20100525/xcache.so [xcache.admin] xcache.admin.auth = On xcache.admin.user = "mOo" ; xcache.admin.pass = md5($your_password) xcache.admin.pass = "" [xcache] xcache.shm_scheme = "mmap" xcache.size = 32M xcache.count = 1 xcache.slots = 8K xcache.ttl = 3600 xcache.gc_interval = 300 ; Same as aboves but for variable cache ; If you don't know for sure that you need this, you probably don't xcache.var_size = 0M xcache.var_count = 1 xcache.var_slots = 8K xcache.var_ttl = 0 xcache.var_maxttl = 0 xcache.var_gc_interval = 300 ; N/A for /dev/zero xcache.readonly_protection = Off xcache.mmap_path = "/dev/zero" xcache.cacher = On xcache.stat = On
php-fpm.conf
user = huangdd
group =huangdd
nginx.conf
#user nobody;
worker_processes 8;
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#pid logs/nginx.pid;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
fastcgi_connect_timeout 300;
fastcgi_send_timeout 300;
fastcgi_read_timeout 300;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
#access_log logs/access.log main;
sendfile on;
#tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 65;
include hosts/*.conf;
}
hosts下的conf文件(css、js合并脚本)
server
{
listen 80;
server_name abc.huangdingding.cn;
index index.html index.php;
root /data0/abc;
location ~ .*\.php?$
{
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi.conf;
}
location /js/ { #合并js
root /data0/abc/public/;
concat on;#开关
}
location /css/ { #合并css
root /data0/abc/public/;
concat on;#开关
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|ico)$
{
expires 30d;
}
location ~ .*\.(js|css)?$
{
expires 30d;
}
location ~ .*\.(swf)$
{
expires 100d;
}
access_log /data0/logs/abc/$remote_addr.log main; #这里是按照来放ip记录日志。
}
本博客所有文章如无说明,则均为作者黄丁丁原创
转载请注明出处:http://www.cnblogs.com/huangdingding
浙公网安备 33010602011771号