Update Caddyfile

Enable Cache Enabler and Security Module
This commit is contained in:
2024-07-16 19:15:31 +07:00
committed by GitHub
parent 0cdcb2359b
commit 1fc5aac2f0
+4 -4
View File
@@ -1,12 +1,12 @@
(cache_enabler) {
@cache_ena {
@cache_enabler {
not header_regexp Cookie "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_logged_in"
not path_regexp "(/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)"
not method POST
not expression {query} != ''
}
route @cache_ena {
route @cache_enabler {
try_files /wp-content/cache/cache-enabler/{host}{uri}/https-index.html /wp-content/cache/cache-enabler/{host}{uri}/index.html {path} {path}/index.php?{query}
}
}
@@ -40,6 +40,6 @@
X-Content-Type-Options "nosniff"
}
#import cache_enabler
#import wordpress_security
import cache_enabler
import wordpress_security
}