diff --git a/ubuntu/erlking.asininetech.net.yml b/ubuntu/erlking.asininetech.net.yml index 4f97093..c029049 100644 --- a/ubuntu/erlking.asininetech.net.yml +++ b/ubuntu/erlking.asininetech.net.yml @@ -32,7 +32,7 @@ - set $cache_uri $request_uri - if ( $request_method = POST ) { set $cache_uri 'null cache'; } - if ( $query_string != "" ) { set $cache_uri 'null cache'; } - - if ( $request_uri ~* "/wp-admin/|/xmlrpc.php|/wp-(app|cron|login|register|mail).php|wp-.*.php|/feed/|index.php|wp-comments-popup.php|wp-links-opml.php|wp-locations.php |sitemap(_index)?.xml|[a-z0-9_-]+-sitemap([0-9]+)?.xml") { set $cache_uri 'null cache'; } + - if ( $request_uri ~* "/wp-admin/|/xmlrpc.php|/wp-(app|cron|login|register|mail).php|wp-.*.php|/feed/|index.php|wp-comments-popup.php|wp-links-opml.php|wp-locations.php |sitemap(_index)?.xml|[a-z0-9_-]+-sitemap([0-9]+)?.xml" ) { set $cache_uri 'null cache'; } - if ( $http_cookie ~* "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_logged_in" ) { set $cache_uri 'null cache'; } - location / { try_files /wp-content/cache/supercache/$http_host/$cache_uri/index.html $uri $uri/ /index.php?$args; @@ -86,8 +86,16 @@ - ssl_stapling on - resolver [::1] valid=300s - add_header Strict-Transport-Security max-age=31536000 + - set $cache_uri $request_uri + - if ( $request_method = POST ) { set $cache_uri 'null cache'; } + - if ( $query_string != "" ) { set $cache_uri 'null cache'; } + - if ( $request_uri ~* "/wp-admin/|/xmlrpc.php|/wp-(app|cron|login|register|mail).php|wp-.*.php|/feed/|index.php|wp-comments-popup.php|wp-links-opml.php|wp-locations.php |sitemap(_index)?.xml|[a-z0-9_-]+-sitemap([0-9]+)?.xml" ) { set $cache_uri 'null cache'; } + - if ( $http_cookie ~* "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_logged_in" ) { set $cache_uri 'null cache'; } - location / { - try_files $uri $uri/ /index.php?$args; + try_files /wp-content/cache/supercache/$http_host/$cache_uri/index.html $uri $uri/ /index.php?$args; + } + - location ~* \.(ogg|ogv|svg|svgz|eot|otf|woff|mp4|ttf|css|rss|atom|js|jpg|jpeg|gif|png|ico|zip|tgz|gz|rar|bz2|doc|xls|exe|ppt|tar|mid|midi|wav|bmp|rtf)$ { + expires max; } - location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { expires 24h; @@ -237,11 +245,16 @@ - ssl_stapling on - resolver [::1] valid=300s - add_header Strict-Transport-Security max-age=31536000 + - set $cache_uri $request_uri + - if ( $request_method = POST ) { set $cache_uri 'null cache'; } + - if ( $query_string != "" ) { set $cache_uri 'null cache'; } + - if ( $request_uri ~* "/wp-admin/|/xmlrpc.php|/wp-(app|cron|login|register|mail).php|wp-.*.php|/feed/|index.php|wp-comments-popup.php|wp-links-opml.php|wp-locations.php |sitemap(_index)?.xml|[a-z0-9_-]+-sitemap([0-9]+)?.xml" ) { set $cache_uri 'null cache'; } + - if ( $http_cookie ~* "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_logged_in" ) { set $cache_uri 'null cache'; } - location / { - try_files $uri $uri/ /index.php?$args; + try_files /wp-content/cache/supercache/$http_host/$cache_uri/index.html $uri $uri/ /index.php?$args; } - - location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { - expires 24h; + - location ~* \.(ogg|ogv|svg|svgz|eot|otf|woff|mp4|ttf|css|rss|atom|js|jpg|jpeg|gif|png|ico|zip|tgz|gz|rar|bz2|doc|xls|exe|ppt|tar|mid|midi|wav|bmp|rtf)$ { + expires max; } - location ~ \.php$ { try_files $uri =404; @@ -270,11 +283,16 @@ - ssl_stapling on - resolver [::1] valid=300s - add_header Strict-Transport-Security max-age=31536000 + - set $cache_uri $request_uri + - if ( $request_method = POST ) { set $cache_uri 'null cache'; } + - if ( $query_string != "" ) { set $cache_uri 'null cache'; } + - if ( $request_uri ~* "/wp-admin/|/xmlrpc.php|/wp-(app|cron|login|register|mail).php|wp-.*.php|/feed/|index.php|wp-comments-popup.php|wp-links-opml.php|wp-locations.php |sitemap(_index)?.xml|[a-z0-9_-]+-sitemap([0-9]+)?.xml" ) { set $cache_uri 'null cache'; } + - if ( $http_cookie ~* "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_logged_in" ) { set $cache_uri 'null cache'; } - location / { - try_files $uri $uri/ /index.php?$args; + try_files /wp-content/cache/supercache/$http_host/$cache_uri/index.html $uri $uri/ /index.php?$args; } - - location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { - expires 24h; + - location ~* \.(ogg|ogv|svg|svgz|eot|otf|woff|mp4|ttf|css|rss|atom|js|jpg|jpeg|gif|png|ico|zip|tgz|gz|rar|bz2|doc|xls|exe|ppt|tar|mid|midi|wav|bmp|rtf)$ { + expires max; } - location ~ \.php$ { try_files $uri =404;