Update Caddy

Signed-off-by: Bensuperpc <bensuperpc@gmail.com>
This commit is contained in:
Bensuperpc 2023-04-12 21:43:52 +02:00
parent 951e5b2956
commit 1e912164a6
No known key found for this signature in database
GPG Key ID: D00C6B1021747EED

View File

@ -1,19 +1,40 @@
bensuperpc.org { bensuperpc.org {
root * /var/www/html # push
php_fastcgi wordpress:9000
file_server
encode gzip
@disallowed { root * /var/www/html
path /xmlrpc.php php_fastcgi wordpress:9000
path *.sql
path /wp-content/uploads/*.php
}
rewrite @disallowed '/index.php'
respond /uploads/*.php 404 file_server
encode zstd gzip
metrics /metrics
@disallowed {
path /xmlrpc.php
path *.sql
path /wp-content/uploads/*.php
}
rewrite @disallowed '/index.php'
respond /uploads/*.php 404
header {
-Server
Content-Security-Policy default-src 'self' *.bensuperpc.org
X-XSS-Protection 1; mode=block
Strict-Transport-Security max-age=31536000; includeSubDomains; preload
X-Frame-Options DENY
X-Frame-Options: SAMEORIGIN
X-Content-Type-Options nosniff
Referrer-Policy no-referrer-when-downgrade
}
log {
output stdout
format console
}
} }
www.bensuperpc.com { www.bensuperpc.com {
redir https://bensuperpc.org{uri} redir https://bensuperpc.org{uri}
} }