Add Cache-Enabler support

This commit is contained in:
VirtuBox
2019-08-15 19:59:23 +02:00
parent cdb195bd03
commit 25c1d8a19b
9 changed files with 99 additions and 117 deletions

View File

@@ -0,0 +1,19 @@
# WPCE NGINX CONFIGURATION - WO v3.9.7
# DO NOT MODIFY, ALL CHANGES WILL BE LOST AFTER AN WordOps (wo) UPDATE
# $cache_uri variable set in /etc/nginx/conf.d/map-wp.conf
# Use cached or actual file if they exists, Otherwise pass request to WordPress
location / {
try_files /wp-content/cache/cache-enabler/${http_host}${cache_uri}index.html $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
try_files $uri =404;
include fastcgi_params;
fastcgi_pass {{upstream}};
}
location ~* /cache/cache-enabler/\.html$ {
etag on;
add_header Vary "Accept-Encoding, Cookie";
access_log off;
log_not_found off;
expires 10h;
}