That’s quite an old version. The latest is v2.5.1.
Since you installed with DO, I think you just didn’t yet run a package update on that machine. Please do, by running sudo apt update && sudo apt upgrade
which should update Caddy as well.
As I said in the other topic, you’re not using matchers correctly. It doesn’t make sense to put the domain as your matcher, because you’re already in that site block. The inline matchers support path matching.
And for your last proxy, you need to use the rewrite
directive to perform a rewrite if you need it. I don’t think you do though, I think that’s just a misunderstanding with how reverse_proxy
works. Are you trying to proxy everything except /blog/*
to myleadpagesip
, whatever that is? In that case, just do reverse_proxy myleadpagesip
(it’ll default to port 80 if you don’t specify a port).
Yeah, you can do a redirect like this:
@blogQuery {
path /blog/
query p=*
}
redir @blogQuery https://{host}/blog/{query.p}
Matches a request with the path being exactly /blog/
and having a query p
with any value (i.e. *
) and then redirects the browser to make a new request at the new URL.