I’m attempting to get Caddy to work in place of my existing nginx setup as I quite like the built in cert configuration, however I’ve suddenly become unable to make any requests to caddy without it either 403 or 404’ing my request without any log messages.
It initially worked as a “Hello World” test, but once I configured things such as a reverse proxy on a subdomain it just suddenly stopped working. All the rewrites occur correctly, and it correctly redirects to HTTPS versions of my addresses, but nothing is ever logged. If specified, a log file will be created, but forever empty.
I am running Caddy on the same machine I’m making the requests from, and as stated it initially worked using my domain name just as nginx is still happily doing. If I attempt to make a request to localhost or 127.0.0.1 however, I do get a log message, stating there is no website under that address, but I only get that log when running Caddy with the -log flag.
My caddyfile is as follows, with my domain name replaced:
example.ca {
root C:\caddy\html
gzip
log stdout
errors
}
plex.example.ca {
root C:\caddy\html
log stdout
errors
rewrite / {
regexp (.*)
to /web{1}
}
proxy / localhost:32400 {
transparent
}
}
sonarr.example.ca {
log stdout
errors
proxy / localhost:38082 {
transparent
}
}
If I request plex.example.ca, it rewrites the url regardless of if the rewrite statement is defined to /web/index.html as plex expects, but I still get a 404.
Finally, I have also tested access from the internet via my cellphone on it’s data connection and I get the same results.
I’m at a complete loss, as nothing I’ve done has worked and I can’t seem to find anyone with a similar issue. Any help would be greatly appreciated.