Zkitzo
(Alex)
May 5, 2020, 2:10am
1
1. My Caddy version (caddy version
):
v2.0.0 h1:pQSaIJGFluFvu8KDGDODV8u4/QRED/OPyIR+MWYYse8=
2. How I run Caddy:
caddy run
a. System environment:
Windows 10
d. My complete Caddyfile or JSON config:
sub1.domain1.com, sub2.otherdomain.com {
tls my@email.com
basicauth /movies/* {
user <verylongencryptedpassword>
}
basicauth /series/* {
user <verylongencryptedpassword>
}
reverse_proxy /movies 127.0.0.1:7878
reverse_proxy /series 127.0.0.1:8989
log stdout
}
3. The problem I’m having:
Sonarr and Radarr are working on Caddy v1 with websocket and transparant, but it seems to keep loading on Caddy v2.
4. Error messages and/or full log output:
5. What I already tried:
Searched Google, but no Sonarr or Radarr user seems to be on Caddy V2 yet.
6. Links to relevant resources:
Functionally, the v1 expires directive allowed for:
A method to match what requests you want to specify expiration for
Dynamic generation of Expires and Cache-Control headers based on provided duration
Currently, in v2, you can replicate some of the functionality right now, just with matchers and the v2 header directive.
The Expires HTTP header is intended to be a fixed datetime after which the response is considered stale. This header can’t easily be replicated dynamically.
However, Cache-…
I think it’s probably because you’re missing the *
on your reverse proxies. In v2, path matchers are exact match, so you need to have the *
to tell it to allow stuff after it.
reverse_proxy /movies* 127.0.0.1:7878
reverse_proxy /series* 127.0.0.1:8989
2 Likes
what’s the difference between /movies* and /movies/*
thanks
Zkitzo
(Alex)
May 5, 2020, 10:50am
4
It’s working, thank you so much
Good question!
/movies*
will match requests like /movies
, /moviesabc
and /movies/abc
.
/movies/*
will not match /movies
or /moviesabc
, but will match /movies/
and /movies/abc
.
If it’s an issue for you if /movies*
matches /moviesabc
, then you can use /movies/*
and add a redir
directive to ensure that /movies
is redirected to /movies/
so that it always has a trailing slash. For example:
redir /movies /movies/ 308
4 Likes
system
(system)
Closed
June 4, 2020, 12:55pm
6
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.