[SOLVED] Reverse proxy subdomain and location

I’m guessing this has some to do with the way Caddy does routing.
Nginx’s location blocks differ somehow from Caddy’s “equivalent” (matchers).

The following article in the Wiki gives some insight regarding that:

From what I understand, this could solve your problem:

comics.chrisrees.dev {
	handle /admin {
		reverse_proxy 172.18.0.12:2203
	}
	handle {
		reverse_proxy 172.18.0.12:2202
	}
	tls {
		dns cloudflare {env.CLOUDFLARE_API_KEY}
	}
}

Or maybe /admin* or /admin/* or any conjugation of that.

Another thing that comes to my mind is a problem with base URLs.
The software you’re using might allow you to configure that.

Following page gives some insight (it’s for Nginx but might help):

2 Likes