Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- user www-data;
- #set worker processes to cpu processes
- worker_processes 4;
- error_log /var/log/nginx/error.log;
- pid /run/nginx.pid;
- events {
- worker_connections 1024;
- }
- http {
- client_max_body_size 200m;
- include /etc/nginx/mime.types;
- default_type application/octet-stream;
- access_log /var/log/nginx/access.log;
- sendfile on;
- keepalive_timeout 3;
- types_hash_max_size 2048;
- gzip on;
- gzip_disable msie6;
- gzip_static on;
- gzip_types text/plain text/css application/x-javascript text/xml application/xml+rss text/javascript;
- gzip_vary on;
- fastcgi_read_timeout 2m;
- include global/caching.conf;
- include /etc/nginx/enabled-sites/*;
- upstream php {
- server 127.0.0.1:9000;
- }
- #fastcgi caching header
- add_header mcapp-fastcgi-cache $upstream_cache_status;
- }
- server {
- server_name www.examplesite.com;
- rewrite ^ $scheme://examplesite.com$request_uri permanent;
- }
- server {
- #pagespeed directives
- pagespeed On;
- pagespeed FileCachePath /var/cache/nginx-pagespeed;
- location ~ ".pagespeed.([a-z].)?[a-z]{2}.[^.]{10}.[^.]+" {
- add_header "" "";
- }
- location ~ "^/ngx_pagespeed_static/" { }
- location ~ "^/ngx_pagespeed_beacon$" { }
- #pagespeed directives end
- server_name examplesite.com;
- root /path/to/examplesite;
- # wordpress config
- include global/restrictions.conf;
- include global/wordpress.conf;
- }
- Enable compression for the following resources to reduce their transfer size by 355.5KiB (69% reduction).
- Compressing http://examplesite.com/wp-includes/js/jquery/jquery.js,qver=1.10.2.pagespeed.jm.iCH2ukpEYb.js could save 58.8KiB (64% reduction).
- Compressing http://examplesite.com/wp-content/themes/Avada/framework/plugins/revslider/rs-plugin/js/jquery.themepunch.revolution.min.js?ver=3.6.1 could save 43.9KiB (80% reduction).
- gzip_types text/plain text/css application/x-javascript text/xml application/xml+rss text/javascript;
- gzip_types text/plain text/css application/javascript text/xml application/xml+rss;
- gzip_types text/plain text/css application/javascript text/xml application/xml+rss;
- application/x-javascript js;
- application/javascript js;
- service nginx reload
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement