mirror of
https://github.com/nmasur/dotfiles
synced 2024-11-09 22:12:56 +00:00
fix path for transmission if not in download
This commit is contained in:
parent
eb6b72a25c
commit
0de2c429f2
@ -40,15 +40,15 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
# Create reverse proxy for web UI
|
# Create reverse proxy for web UI
|
||||||
caddy.routes = lib.mkAfter [{
|
caddy.routes = let
|
||||||
group =
|
# Set if the download domain is the same as the Transmission domain
|
||||||
if (config.hostnames.download == config.hostnames.transmission) then
|
useDownloadDomain = config.hostnames.download
|
||||||
"download"
|
== config.hostnames.transmission;
|
||||||
else
|
in lib.mkAfter [{
|
||||||
"transmission";
|
group = if useDownloadDomain then "download" else "transmission";
|
||||||
match = [{
|
match = [{
|
||||||
host = [ config.hostnames.transmission ];
|
host = [ config.hostnames.transmission ];
|
||||||
path = [ "/transmission*" ];
|
path = if useDownloadDomain then [ "/transmission*" ] else null;
|
||||||
}];
|
}];
|
||||||
handle = [{
|
handle = [{
|
||||||
handler = "reverse_proxy";
|
handler = "reverse_proxy";
|
||||||
|
Loading…
Reference in New Issue
Block a user