https://github.com/danilovsergei/docker-qbittorent
5.3K
Docker image with latest qbittorrent from git
Creates image with two tags: latest and buld date, eg. 09_30_2024
Docker image requires to mount two directories. One for downloads and another to keep qbittorrent config.
My config assumes:
You have a system /Storage directory. It will be mount to Qbittorrent docker container with the same name. So specifying '/Storage' as downloads folder while downloading torrent will work
There is a system /home/qbittorrent. It will be mount to /home/qbittorrent local docker folder. This folder is used to keep qbittorrent settings.
It's expected to run it with systemd service. Here is service file in systemd folder
Here is a dump of command line what systemd runs:
/usr/bin/docker run --rm --name qbittorrent --mount type=bind,source=/home/qbittorrent,target=/home/qbittorrent --mount type=bind,source=/Storage,target=/Storage -e WEBUI_PORT=8080 -e CHUID=1000 -e CHGID=1000 -p 6881:6881 -p 6881:6881/udp -p 8080:8080 geonix/qbittorrent:latest
Qbittorrent will listen on <your_host>:8080 port
To update existing docker image run
docker pull geonix/qbittorrent:latest && \
systemctl restart qbittorrent
The main benefit of bundling glider into this image is to allow load balancing and automatically switching to the best proxy on the fly without restarting qBittorrent. Our forked version of glider also includes a patch that fixes SOCKS5 UDP Associate bugs, allowing DHT to work seamlessly through upstream proxies.
To enable the proxy, you must pass the -e ENABLE_GLIDER=true environment variable and mount your glider.conf configuration file to /etc/glider/glider.conf.
docker run -d --name qbittorrent \
--mount type=bind,source=/home/qbittorrent,target=/home/qbittorrent \
--mount type=bind,source=/Storage,target=/Storage \
--mount type=bind,source=/path/to/your/glider.conf,target=/etc/glider/glider.conf \
-e ENABLE_GLIDER=true \
-e WEBUI_PORT=8080 -e CHUID=1000 -e CHGID=1000 \
-p 6881:6881 -p 6881:6881/udp -p 8080:8080 \
geonix/qbittorrent:latest
When glider is enabled, it automatically runs inside the container and binds to 127.0.0.1:1081.
You MUST configure your qBittorrent Connection settings as follows via the WebUI:
127.0.0.11081Below is an example glider.conf that load-balances multiple upstream proxy servers based on connection latency (LHA) while automatically avoiding failing connections:
verbose=True
# Local listener for qBittorrent to connect to (Do not change)
listen=socks5://0.0.0.0:1081
# High availability strategy: "lha" (Latency-based High Availability)
strategy=lha
# Health check interval and timeout (in seconds)
checkinterval=30
checktimeout=10
# Health check target: test TCP connectivity to Google
check=tcp://www.google.com:80
# Maximum failures before marking an upstream proxy as DISABLED
maxfailures=2
# Upstream proxy pool
forward=socks5://user:[email protected]:1080
forward=socks5://user:[email protected]:1080
forward=socks5://user:[email protected]:1080
forward=socks5://user:[email protected]:1080
Content type
Image
Digest
sha256:d8077a95e…
Size
145.8 MB
Last updated
3 days ago
docker pull geonix/qbittorrent