A shell script and Docker container for automatically setting qBittorrent's listening port from Glue
100K+
A shell script and Docker container for automatically setting qBittorrent's listening port from Gluetun's control server.
| Variable | Example | Default | Description |
|---|---|---|---|
| QBT_USERNAME | username | admin | qBittorrent username |
| QBT_PASSWORD | password | adminadmin | qBittorrent password |
| QBT_ADDR | http://192.168.1.100:8080 | http://localhost:8080 | HTTP URL for the qBittorrent web UI, with port |
| GTN_ADDR | http://192.168.1.100:8000 | http://localhost:8000 | HTTP URL for the gluetun control server, with port |
| GTN_USERNAME | username | None | Username for authentication to gluetun control server (if basic auth enabled) |
| GTN_PASSWORD | password | None | Password for authentication to gluetun control server (if basic auth enabled) |
| GTN_APIKEY | apikey | None | API Key for authentication to gluetun control server (if API key auth enabled) |
Starting in Gluetun v3.4, it is required to setup authentication on the Gluetun control server routes.
See this link for information on how to set this up: https://github.com/qdm12/gluetun-wiki/blob/main/setup/advanced/control-server.md#authentication
Once configured in Gluetun, you can configure this container to use the appropriate authentication method:
none auth, you do not need to provide any of the authentication environment variablesbasic auth, you should set the GTN_USERNAME and GTN_PASSWORD environment variablesapikey auth, you should set the GTN_APIKEY environment variableThe following is an example docker-compose:
qbittorrent-port-forward-gluetun-server:
image: mjmeli/qbittorrent-port-forward-gluetun-server
container_name: qbittorrent-port-forward-gluetun-server
restart: unless-stopped
environment:
- QBT_USERNAME=username
- QBT_PASSWORD=password
- QBT_ADDR=http://192.168.1.100:8080
- GTN_ADDR=http://192.168.1.100:8000
- GTN_APIKEY=CHANGEME
docker build . -t qbittorrent-port-forward-gluetun-server
docker run --rm -it -e QBT_USERNAME=admin -e QBT_PASSWORD=adminadmin -e QBT_ADDR=http://192.168.1.100:8080 -e GTN_ADDR=http://192.168.1.100:8000 -e GTN_APIKEY=CHANGEME qbittorrent-port-forward-gluetun-server:latest
Content type
Image
Digest
sha256:e6ab8714e…
Size
6.4 MB
Last updated
9 months ago
docker pull mjmeli/qbittorrent-port-forward-gluetun-server