You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been scrambling to figure out why my local Docker Compose setup utilizing Caddy as a reverse proxy wasn't working and it all boiled down to a single, simple Caddyfile change (using the internal container port instead of the host port).
I have been scrambling to figure out why my local Docker Compose setup utilizing Caddy as a reverse proxy wasn't working and it all boiled down to a single, simple Caddyfile change (using the internal container port instead of the host port).
Link to relevant docs: https://caddyserver.com/docs/running#docker-compose
Link to forum post coment that gave the proper solution: https://caddy.community/t/caddy-foundry-docker-connection-issues/21265/2
I hope this breakdown helps others who may have been banging their heads against the same problem.
I was under the impression that my Caddyfile should look like:
With a Dockerfile like:
But that just resulted in my app being unreachable. In reality all I needed was to utilize the internal container port that was being used by the app.
So my Dockerfile could look like:
With a Caddyfile like:
The text was updated successfully, but these errors were encountered: