From ce7dc528558f766204741d9344f3a70d2bdea6a5 Mon Sep 17 00:00:00 2001 From: Nik Afiq Date: Mon, 12 Jan 2026 00:33:44 +0900 Subject: [PATCH] Updated anime proxy to use djellyfin upstream and added qBittorrent configuration --- nik4nao.home.arpa.conf | 19 +++++++++++++++---- upstreams.conf | 13 +++++++++---- 2 files changed, 24 insertions(+), 8 deletions(-) diff --git a/nik4nao.home.arpa.conf b/nik4nao.home.arpa.conf index 8e1fdba..dbf2a9e 100644 --- a/nik4nao.home.arpa.conf +++ b/nik4nao.home.arpa.conf @@ -39,7 +39,7 @@ server { location = /anime { return 302 /anime/; } # enforce trailing slash location /anime/ { - proxy_pass http://anime_upstream/; # uses upstream (or use the raw URL) + proxy_pass http://djellyfin_upstream/; # uses upstream (or use the raw URL) proxy_next_upstream error timeout invalid_header http_502 http_503 http_504; include snippets/proxy-common.conf; @@ -82,8 +82,19 @@ server { # For Vite HMR / websockets proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection $connection_upgrade; - - # Uncomment if you see odd redirects - # proxy_redirect off; + } + + # ---- qBittorrent at /qbt/ ---- + location = /qbt { return 302 /qbt/; } + + location ^~ /qbt/ { + proxy_pass http://qbt_upstream; + include snippets/proxy-common.conf; + + proxy_set_header X-Forwarded-Host $host; + proxy_set_header X-Forwarded-Proto $scheme; + proxy_set_header X-Forwarded-Prefix /qbt; + + proxy_redirect off; } } diff --git a/upstreams.conf b/upstreams.conf index 0f6b4f9..0565477 100644 --- a/upstreams.conf +++ b/upstreams.conf @@ -14,8 +14,13 @@ upstream watchparty_upstream { keepalive 16; } -upstream anime_upstream { - server 192.168.7.78:8096 max_fails=2 fail_timeout=3s; - server 192.168.7.7:8096 backup; - keepalive 16; + +upstream qbt_upstream { + server 127.0.0.1:8082; + keepalive 32; +} + +upstream djellyfin_upstream { + server 127.0.0.1:8096; + keepalive 32; }