The problem I’m having:
Hey Caddy community.
I have the following in my Caddyfile:
www.mydomain.com {
handle /google1234567890.html {
file_server
}
encode zstd gzip
reverse_proxy my-frontend:3000
import redirects/myredirects
}
in redirects/myredirects there is a rule that redirects paths with a .html suffix to the same path without it:
@htmlSuffix path_regexp htmlSuffix ^(.*).html$
redir @htmlSuffix {http.regexp.htmlSuffix.1}
Now i would like to exclude the /google1234567890.html path, since it’s a verification file for google that needs to be accessible WITH .html suffix.
How can this be achieved?
I’ve tried regex with negative lookahead, but that doesn’t seem to be supported ![]()
Caddy version:
2.8