File tree Expand file tree Collapse file tree 1 file changed +7
-8
lines changed
Expand file tree Collapse file tree 1 file changed +7
-8
lines changed Original file line number Diff line number Diff line change @@ -123,21 +123,20 @@ http {
123123 error_page 410 /error/410 .html;
124124 error_page 500 501 502 503 504 505 /error/50x .html;
125125
126- # Cache settings
126+ # Proxy cache
127127 proxy_cache_path /var/cache/nginx levels=2 keys_zone=cache:10m inactive=60m max_size=1024m ;
128128 proxy_cache_key "$host$request_uri $cookie_user" ;
129129 proxy_temp_path /var/cache/nginx/temp;
130130 proxy_ignore_headers Expires Cache-Control;
131131 proxy_cache_use_stale error timeout invalid_header http_502;
132132 proxy_cache_valid any 1d ;
133133
134- # FastCGI Cache settings
135- fastcgi_cache_path /var/cache/nginx/php-fpm levels=2 keys_zone=fcgi_cache:10m inactive=60m max_size=1024m ;
136- fastcgi_cache_key "$host$request_uri $cookie_user" ;
137- fastcgi_temp_path /var/cache/nginx/temp;
138- fastcgi_ignore_headers Expires Cache-Control;
139- fastcgi_cache_use_stale error timeout invalid_header;
140- fastcgi_cache_valid any 1d ;
134+ # FastCGI cache
135+ fastcgi_cache_path /var/cache/nginx/micro levels=1:2 keys_zone=microcache:10m max_size=1024m inactive=30m ;
136+ fastcgi_cache_key "$scheme$request_method$host$request_uri" ;
137+ fastcgi_cache_methods GET HEAD;
138+ fastcgi_cache_use_stale updating error timeout invalid_header http_500 http_503;
139+ fastcgi_ignore_headers Cache-Control Expires Set-Cookie;
141140
142141 # Cache bypass
143142 map $http_cookie $no_cache {
You can’t perform that action at this time.
0 commit comments