I recently started using qBittorent in a docker container, that only allows traffic through another container using gluetun so it all passes through a VPN without affecting the host network.

It works really well so far. I can share the docker compose file if you are interested.

Reply to this note

Please Login to reply.

Discussion

Yeah would love to see the docker file.

Best way to sent it to you?

github gist?

services:

gluetun:

image: qmcgaw/gluetun

container_name: gluetun

# Hostname to use for container, required in some instances for the rest of the stack to each other endpoints

hostname: gluetun

# line above must be uncommented to allow external containers to connect.

# See https://github.com/qdm12/gluetun-wiki/blob/main/setup/connect-a-container-to-gluetun.md#external-container-to-gluetun

cap_add:

- NET_ADMIN

devices:

- /dev/net/tun:/dev/net/tun

ports:

- 6881:6881

- 6881:6881/udp

- 8085:8085 # qbittorrent

volumes:

- /home/ubuntu/docker/arr-stack/gluetun:/gluetun

environment:

# See https://github.com/qdm12/gluetun-wiki/tree/main/setup#setup

- VPN_SERVICE_PROVIDER=protonvpn

- VPN_TYPE=wireguard

# OpenVPN:

# - OPENVPN_USER=

# - OPENVPN_PASSWORD=

# Wireguard:

- WIREGUARD_PRIVATE_KEY={KEY_HERE} # See https://github.com/qdm12/gluetun-wiki/blob/main/setup/providers/nordvpn.md#obtain-your-wireguard-private-key

# - WIREGUARD_ADDRESSES=10.5.0.2/32

# Timezone for accurate log times

- TZ=Europe/London

# Server list updater

# See https://github.com/qdm12/gluetun-wiki/blob/main/setup/servers.md#update-the-vpn-servers-list

- UPDATER_PERIOD=24h

restart: always

qbittorrent:

image: lscr.io/linuxserver/qbittorrent

container_name: qbittorrent

network_mode: "service:gluetun"

environment:

- PUID=1000

- PGID=1000

- TZ=Europe/London

- WEBUI_PORT=8085

volumes:

- /my-config:/config

- /my-download:/downloads

depends_on:

- gluetun

restart: always