Getting Nginx reverse proxy working with Deluge
|
Posts: 4
Threads: 1
Joined: Apr 2017
Reputation:
0
[Solved]
Apr 05, 2017, 08:01 PM
Hey all, I'm having a heck of a time trying to get an Nginx reverse proxy working for Deluge 1.3.14 running on Windows 10. I have it working successfully with sabnzbd, sonarr, and radarr, but I'm not having any luck with Deluge's Webui.
I can access the Webui with no issues via http://127.0.0.1:8112, but http://127.0.0.1/deluge/ returns the "Sorry, the page you are looking for is currently unavailable." error when using the following config:
location /deluge {
proxy_pass http://127.0.0.1:8112/;
proxy_set_header X-Deluge-Base "/deluge/";
}
I've seen it suggested to edit the Deluge web.conf file to manually specify the url base, i.e > "base": "/deluge/", (normally this is blank i.e. "base": "",)
However when this is active visiting 127.0.0.1:8112 just returns a blank page, while visiting 127.0.0.1/deluge gives me the same error as before.
Visiting 127.0.0.1/sabnzbd; 127.0.0.1/sonarr; and 127.0.0.1/radarr are all working as expected. I've also tried a bunch of other similar nginx configs for Deluge with the same result, any ideas as to what I may be missing? Not sure if there's any other relevant info I should be including here, if so, let me know.
Any suggestions are appreciated, cheers.
Posts: 215
Threads: 25
Joined: Aug 2015
Reputation:
26
[Solved]
Apr 06, 2017, 05:32 PM
Try this:
Code:
location /deluge {
proxy_pass http://localhost:8112/;
proxy_set_header X-Deluge-Base "/deluge/";
include proxy-control.conf;
add_header X-Frame-Options SAMEORIGIN;
}
This is what it says on the Deluge website.
I don't run Deluge myself so if this doesn't work I can't help you any further.
That McNugget sauce. I want that Mulan McNugget sauce, Morty. That's my series arc, Morty! If it takes nine seasons!
Posts: 4
Threads: 1
Joined: Apr 2017
Reputation:
0
[Solved]
Apr 06, 2017, 06:32 PM
(Apr 06, 2017, 05:32 PM)Yveske Wrote: Try this:
Code:
location /deluge {
proxy_pass http://localhost:8112/;
proxy_set_header X-Deluge-Base "/deluge/";
include proxy-control.conf;
add_header X-Frame-Options SAMEORIGIN;
}
This is what it says on the Deluge website.
I don't run Deluge myself so if this doesn't work I can't help you any further.
Probably should have mentioned that I had attempted that config as well, with the same effect. Only reason I'm using Deluge is because it works well with this script: https://github.com/mdhiggins/sickbeard_mp4_automator/ (or µTorrent) otherwise Deluge seems kinda janky; might go back to µTorrent anyways, thanks for the reply though, cheers.
Posts: 215
Threads: 25
Joined: Aug 2015
Reputation:
26
[Solved]
Apr 06, 2017, 07:21 PM
Can't be of anymore assistance.
Probably something small and stupid (like most problems).
Hopefully you find a way to figure it out.
Good luck
That McNugget sauce. I want that Mulan McNugget sauce, Morty. That's my series arc, Morty! If it takes nine seasons!
Posts: 244
Threads: 1
Joined: Jul 2016
Reputation:
12
[Solved]
Apr 12, 2017, 06:44 AM
I'm using nginx with Deluge reverse proxy for a long time and it works perfectly fine, never ever had any issues. Many of our users are running the same configuration without any problems.
Which guide did you follow to configure nginx and Deluge? Our guides? If yes, then you should have a location setting like this in nginx:
Code:
# Deluge
location /deluge {
proxy_pass http://localhost:8112/;
proxy_set_header X-Deluge-Base "/deluge/";
include snippets/proxy-control.conf;
}
Of course, make sure you actually have proxy-control.conf in your nginx snippets folder. If you followed any of our guides, you should have it there. Make sure you have installed Deluge correctly (following our relevant guide).
Deluge is an excellent client, in my opinion the most flexible one available, you can do with it pretty much anything you want, and it does the job great.
Posts: 4
Threads: 1
Joined: Apr 2017
Reputation:
0
[Solved]
Apr 13, 2017, 02:42 AM
(This post was last modified: Apr 13, 2017, 03:05 AM by evilmanimani.)
(Apr 12, 2017, 06:44 AM)drake Wrote: I'm using nginx with Deluge reverse proxy for a long time and it works perfectly fine, never ever had any issues. Many of our users are running the same configuration without any problems.
Which guide did you follow to configure nginx and Deluge? Our guides? If yes, then you should have a location setting like this in nginx:
Code:
# Deluge
location /deluge {
proxy_pass http://localhost:8112/;
proxy_set_header X-Deluge-Base "/deluge/";
include snippets/proxy-control.conf;
}
Of course, make sure you actually have proxy-control.conf in your nginx snippets folder. If you followed any of our guides, you should have it there. Make sure you have installed Deluge correctly (following our relevant guide).
Deluge is an excellent client, in my opinion the most flexible one available, you can do with it pretty much anything you want, and it does the job great.
I seem to be missing the "include snippets/proxy-control.conf;" line, and I can't find proxy-control.conf either, I'm guessing I have to create that myself? My nginx installation is on Windows, and the guide on the site for Deluge and the reverse proxying thereof are specifically for Linux, so I just entered it as closely as possible; I'm not too sure what should be contained in the proxy-control.conf file, any tips?
edit:
So I found the proxy-control.conf to use here: https://github.com/alexgorbatchev/nginx-...ntrol.conf but since adding that to my nginx.conf, I can get to the WebUI, but it's broken as described in this thread here:
https://www.reddit.com/r/torrents/commen...ui_broken/
Just to try something different, I tried setting up Caddy for reverse proxy (guide found here: https://www.reddit.com/r/usenet/comments...asy_guide/ ), and was able to get Deluge working perfectly, just not SABnzbd. I can't win! Haha, anyways. Anyone have any tips for fixing the Webui issue while using Nginx, that wouldn't require going to Python2.6? Pretty sure I have a few services going that would break by downgrading, and would rather not deal with the hassle If I can avoid it. Cheers.
Posts: 4
Threads: 1
Joined: Apr 2017
Reputation:
0
[Solved]
Apr 22, 2017, 12:53 AM
So in case anyone else is curious, I ditched nginx and got things working well for myself using Caddy. HTTPS is enabled by default as well so there's no messing around with generating certs and running into self-signed cert errors. You can use the following in a text document called 'caddyfile' (no extension) in the same directory as the exe, just update with your own domain of course. The problem I had earlier using Caddy with sabnzbd is that i had sab listening on an internal IP (192.168.0.xx) instead of 0.0.0.0 (all interfaces), after changing it, it worked perfectly.
Code:
yourdomain.com {
rewrite {
if_op or
if {>Referer} has /deluge
if {>Referer} has yourdomain.com/themes/css/
if {>Referer} has yourdomain.com/css/
to /deluge/{path}
}
proxy /sabnzbd localhost:8080 {
transparent
}
proxy /sonarr localhost:8084
proxy /radarr localhost:7878
proxy /deluge localhost:8112 {
without /deluge
transparent
header_upstream X-Forwarded-Host {host}
}
}
#The following config is the same is above, but allows locations to work while on the local machine
http://localhost {
rewrite {
if_op or
if {>Referer} has /deluge
if {>Referer} has http://localhost/themes/css/
if {>Referer} has http://localhost/css/
to /deluge/{path}
}
proxy /sabnzbd localhost:8080 {
transparent
}
proxy /sonarr localhost:8084
proxy /radarr localhost:7878
proxy /deluge localhost:8112 {
without /deluge
transparent
header_upstream X-Forwarded-Host {host}
}
}
If you want to run Caddy as a service on Windows just use https://nssm.cc/
Posts: 244
Threads: 1
Joined: Jul 2016
Reputation:
12
[Solved]
Apr 25, 2017, 09:21 AM
Thanks for the feedback!
The problem is with Windows and nginx. On Linux it is working perfectly fine. Please note, these guides (except where noted differently) are for Linux and Windows. There are many reasons why we (and 95% of the community) prefer Linux for these tasks, and I can strongly advise that you try as well. Most things will probably work to some extent on Windows, but you will never ever have the same functionality you get with Linux.
|
|
Recent Posts
|
About Swap
jonescelinaa Apr 10, 2024, 06:58 AM
|
Tracker Status: Error Connection Time Out
jonesPhedra Apr 04, 2024, 08:17 AM
|
Split Tunnel Docker Containers
jonesPhedra Mar 27, 2024, 03:10 AM
|
Plex server not powerful enough, but only with s...
jonesPhedra Mar 27, 2024, 03:02 AM
|
game Geometry Dash Scratch
jonescelinaa Jan 31, 2024, 04:21 AM
|
Latest unread posts | Unanswered posts |
|