Simplify Caddy configuration
Remove the force removing of trailing slashes from URLs.
This commit is contained in:
parent
6da0e7fd91
commit
449f331fb5
1 changed files with 1 additions and 12 deletions
|
@ -14,20 +14,9 @@
|
||||||
extraConfig =
|
extraConfig =
|
||||||
''
|
''
|
||||||
encode gzip
|
encode gzip
|
||||||
|
file_server
|
||||||
root * /var/www/vhosts/www.oliverdavies.uk
|
root * /var/www/vhosts/www.oliverdavies.uk
|
||||||
|
|
||||||
file_server {
|
|
||||||
disable_canonical_uris
|
|
||||||
}
|
|
||||||
|
|
||||||
# Remove trailing slashes from all URLs.
|
|
||||||
@trailingSlash {
|
|
||||||
path_regexp trailingSlash ^(.*)/$
|
|
||||||
not path /
|
|
||||||
}
|
|
||||||
redir @trailingSlash {http.regexp.trailingSlash.1} temporary
|
|
||||||
|
|
||||||
handle_errors {
|
handle_errors {
|
||||||
@404 {
|
@404 {
|
||||||
expression {http.error.status_code} == 404
|
expression {http.error.status_code} == 404
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue