Try to use Caddy to proxy Portainer


I am trying to use Caddy to proxy Portainer.
Portainer is an open-source management UI for Docker.

So I edit the Caddyfile like this:
log ./caddy.log
proxy /xyzxyz {
header_upstream -Origin
proxy /portainer {
header_upstream -Origin
header / Strict-Transport-Security “max-age=31536000;”

But it does not work,when I visit,it shows 404 page not foundthe log file shows [28/Oct/2018:16:06:38 +0000] "GET /portainer HTTP/2.0" 404 19.
but when I visit server_ip:9000,it works well.
And the,it works well too.

When you visit, Caddy will attempt to request (note that the URI carries through).

Portainer expects to be accessed at the URI /, not at /portainer.

1 Like

Oh, I understand.

Thank you very much.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.