抱歉,您的浏览器无法访问本站

本页面需要浏览器支持(启用)JavaScript


了解详情 >

一行命令安装:

1
apt install qbittorrent-nox

openmediavault自带一个bt下载器:Transmission,用了一段时间感觉webui功能比较少,自己换ui比较麻烦,索性装个qBittorrent

OMV4的版本使用apt安装qBittorrent最高支持到v3.3.7,PT助手仅支持v4.1+,所以准备用qBittorrent配合PT助手使用的话建议放弃

官方教程(没啥用):

https://github.com/qbittorrent/qBittorrent/wiki/Installing-qBittorrent

启动并配置:

使用qbittorrent-nox命令启动
看到以下提示

1
2
3
4
5
******** 信息 ********
欲通过网页端控制 qBittorrent,你需要访问 http://localhost:8080
网页端管理员的用户名是:admin
网络端管理员密码设置为默认密码:adminadmin
存在安全风险!请考虑在设置更改密码!

此时根据提示浏览器打开网页即可进入webiu

可以配置下载端口、web端口、用户名密码、下载位置、限速等

使用Nginx反向代理

根据官网文档配置即可:

https://github.com/qbittorrent/qBittorrent/wiki/NGINX-Reverse-Proxy-for-Web-UI

比如我的:

编辑vim /etc/nginx/sites-enabled/proxy

插入以下内容:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
location /qbt/ {
proxy_pass http://127.0.0.1:8080/;
proxy_http_version 1.1;
proxy_set_header X-Forwarded-Host $http_host;
#http2_push_preload on; # Enable http2 push

# The following directives effectively nullify Cross-site request forgery (CSRF)
# protection mechanism in qBittorrent, only use them when you encountered connection problems.
# You should consider disable "Enable Cross-site request forgery (CSRF) protection"
# setting in qBittorrent instead of using these directives to tamper the headers.
# The setting is located under "Options -> WebUI tab" in qBittorrent since v4.1.2.
#proxy_hide_header Referer;
#proxy_hide_header Origin;
#proxy_set_header Referer '';
#proxy_set_header Origin '';

# Not needed since qBittorrent v4.1.0
#add_header X-Frame-Options "SAMEORIGIN";
}

需要注意的是,openmediavault自带的nginx版本比较低(1.10.3),配置文件中的http2_push_preload on; # Enable http2 pushHTTP/2服务端推送的功能是在1.13.9版本支持的,所以需要注释掉这一行。

开机自动启动/后台运行

设置到这里我准备在PT助手里添加服务器,结果发现PT助手不支持4.1以下版本,考虑到自己编译或升级OMV5都需要较大的精力,所以到这我就放弃了……等OMV6出来再升级吧……

配置开机自动启动和后台运行请直接参照官网文档:

文档地址

评论