1. The problem I’m having:
I am using Caddy with forward_auth with Authelia. For my Aria2 service, my Caddyfile is the following:
aria2.redacted.com {
forward_auth authelia:9091 {
copy_headers Remote-User Remote-Groups Remote-Name Remote-Email
uri /api/verify?rd=https://authelia.redacted.com/
}
reverse_proxy /rpc/* aria2:6800
reverse_proxy ariang:6880
}
AriaNG is the WebUI, Aria2 is the API accessible via RPC. I want AriaNG (so everything behind the subdomain) to be secured behind Authelia via forward_auth. But the subpath /rpc/* must not be included in the forward_auth, as RPC can’t connect.
Simply put, how can I exclude the path /rpc/* from forward_auth, while still including every other path and the base subdomain ?
Thanks in advance for any answer, have a great day.
2. Error messages and/or full log output:
PASTE OVER THIS, BETWEEN THE ``` LINES.
Please use the preview pane to ensure it looks nice.
3. Caddy version:
v2.6.4
4. How I installed and ran Caddy:
Caddy docker container
a. System environment:
Docker, Raspberry Pi 4, LibreELEC.
b. Command:
PASTE OVER THIS, BETWEEN THE ``` LINES.
Please use the preview pane to ensure it looks nice.
c. Service/unit/compose file:
PASTE OVER THIS, BETWEEN THE ``` LINES.
Please use the preview pane to ensure it looks nice.
d. My complete Caddy config:
PASTE OVER THIS, BETWEEN THE ``` LINES.
Please use the preview pane to ensure it looks nice.