How to Set Up qBittorrent with VPN, Sonarr, Radarr & Prowlarr on TrueNAS Scale
Running a home media server is one thing. Running one that automatically finds, downloads, organises, and streams your content all while keeping your traffic private behind a VPN is a completely different level. That is exactly what this guide covers.
By the end, your TrueNAS Scale NAS will have a fully automated media pipeline. Prowlarr manages your torrent indexers. Sonarr handles TV shows. Radarr handles movies. qBittorrent does the actual downloading. And Gluetun wraps all of it inside a ProtonVPN WireGuard tunnel so your ISP never sees what you are doing. Jellyfin then picks up the finished files and serves them to every screen in your home.
Before touching any configuration, understand what each piece does and why it belongs in the setup.
- TrueNAS Scale installed and accessible on your local network
- A storage pool created this guide uses a pool named Pool
- Jellyfin installed with your media dataset already configured
- A paid ProtonVPN account the free tier lacks port forwarding and uses throttled servers
- Dockge installed from the TrueNAS community app catalog
- Basic comfort navigating the TrueNAS web interface
Dockge is a visual Docker Compose manager that runs as a TrueNAS app. It gives you a clean UI to deploy and manage multi-container stacks without touching the command line for most tasks.
- Go to Apps → Discover Apps and search for Dockge
- Install it, pointing Dockge Stacks Storage to /mnt/Pool/dockge as a Host Path
- Note the WebUI port number shown after installation completes
- Access Dockge at http://YOUR_TRUENAS_IP:PORT in your browser
Once inside Dockge, any compose stacks you deploy appear in the left sidebar with real-time container status. It also streams logs from every container in one place, which makes troubleshooting straightforward.
All six services live in a single compose file. Every container except Gluetun itself uses network_mode: service:gluetun this means they share Gluetun's network interface and all their traffic routes through the VPN tunnel automatically.
In Dockge, click + Compose, name your stack media-stack, and paste the following:
version: "3" services: gluetun: image: qmcgaw/gluetun container_name: gluetun cap_add: - NET_ADMIN dns: - 8.8.8.8 - 1.1.1.1 ports: - "8081:8080" # qBittorrent WebUI - "8989:8989" # Sonarr - "7878:7878" # Radarr - "9696:9696" # Prowlarr - "8191:8191" # FlareSolverr environment: - VPN_SERVICE_PROVIDER=protonvpn - VPN_TYPE=wireguard - WIREGUARD_PRIVATE_KEY=<YOUR_PRIVATE_KEY_HERE> - WIREGUARD_ADDRESSES=10.2.0.2/32 - SERVER_COUNTRIES=Singapore - DOT=off - FIREWALL_OUTBOUND_SUBNETS=192.168.0.0/24 restart: unless-stopped qbittorrent: image: lscr.io/linuxserver/qbittorrent:latest container_name: qbittorrent network_mode: service:gluetun environment: - PUID=568 - PGID=568 - TZ=Asia/Kathmandu - WEBUI_PORT=8080 volumes: - /mnt/Pool/config/qbittorrent:/config - /mnt/Pool/Jellyfin/JellyFin_Content:/downloads depends_on: - gluetun restart: unless-stopped sonarr: image: lscr.io/linuxserver/sonarr:latest container_name: sonarr network_mode: service:gluetun environment: - PUID=568 - PGID=568 - TZ=Asia/Kathmandu volumes: - /mnt/Pool/config/sonarr:/config - /mnt/Pool/Jellyfin/JellyFin_Content:/media depends_on: - gluetun restart: unless-stopped radarr: image: lscr.io/linuxserver/radarr:latest container_name: radarr network_mode: service:gluetun environment: - PUID=568 - PGID=568 - TZ=Asia/Kathmandu volumes: - /mnt/Pool/config/radarr:/config - /mnt/Pool/Jellyfin/JellyFin_Content:/media depends_on: - gluetun restart: unless-stopped prowlarr: image: lscr.io/linuxserver/prowlarr:latest container_name: prowlarr network_mode: service:gluetun environment: - PUID=568 - PGID=568 - TZ=Asia/Kathmandu volumes: - /mnt/Pool/config/prowlarr:/config depends_on: - gluetun restart: unless-stopped flaresolverr: image: ghcr.io/flaresolverr/flaresolverr:latest container_name: flaresolverr network_mode: service:gluetun environment: - LOG_LEVEL=info - TZ=Asia/Kathmandu depends_on: - gluetun restart: unless-stopped networks: {}
WireGuard is the right choice over OpenVPN here. It is faster, uses less CPU, and establishes connections in milliseconds. On a low-power processor like the Intel N100, the difference is meaningful under sustained load.
- Log in at account.proton.me and go to VPN → Downloads → WireGuard configuration
- Select a server with low load percentage — servers at 10–20% load give the best performance
- Select WireGuard as the protocol and download the config file
- Copy the PrivateKey value from the [Interface] section and paste it into your compose file
| Variable | Value | Purpose |
|---|---|---|
| VPN_SERVICE_PROVIDER | protonvpn | Tells Gluetun which provider's server list to use |
| VPN_TYPE | wireguard | Protocol selection WireGuard is faster than OpenVPN |
| WIREGUARD_ADDRESSES | 10.2.0.2/32 | Your VPN tunnel IP from the ProtonVPN config file |
| DOT=off | off | Disables DNS-over-TLS, preventing DNS resolution failures on startup |
| FIREWALL_OUTBOUND_SUBNETS | 192.168.0.0/24 | Allows containers to reach your local network for qBittorrent and Jellyfin communication |
After deploying the stack, open the Gluetun container logs in Dockge. A successful connection shows:
INFO [wireguard] Connecting to 149.50.211.164:51820 INFO [vpn] wireguard setup is complete INFO [ip getter] Public IP address is 159.26.115.129 (Singapore, Singapore)
That Singapore IP confirms your traffic is leaving through ProtonVPN and not your real ISP connection. Every container sharing Gluetun's network uses this same tunnel.
With all containers running, the wiring is straightforward. Prowlarr acts as the central hub — configure indexers once there and it pushes them to both Sonarr and Radarr automatically.
- Open Prowlarr at http://YOUR_NAS_IP:9696 and go to Settings → Apps → Add
- Add Sonarr — Server: http://localhost:8989 — API Key: copy from Sonarr → Settings → General
- Add Radarr — Server: http://localhost:7878 — API Key: copy from Radarr → Settings → General
- Both should show Full Sync status when connected successfully
Go to Indexers → Add Indexer and add the following. Test each one before saving:
- YTS best for high-quality movie releases, works reliably through VPN
- EZTV solid TV show indexer
- Nyaa.si essential if you watch anime
- 1337x general purpose, requires FlareSolverr (see next section)
- TorrentGalaxy good fallback for both movies and TV
In both Sonarr and Radarr, go to Settings → Download Clients → Add → qBittorrent and enter your NAS IP, qBittorrent port, username, and password. Click Test if it returns green, save it.
In Radarr → Settings → Media Management → Root Folders, add /media/Movies. In Sonarr, add /media/TV. These paths match the volume mounts defined in the compose file.
Many popular torrent indexers use Cloudflare bot protection. When Prowlarr running behind a VPN IP tries to access sites like 1337x, Cloudflare blocks the request. FlareSolverr sits between Prowlarr and the indexer, handling the challenge automatically.
- Go to Prowlarr → Settings → Indexers → Indexer Proxies → Add
- Select FlareSolverr as the proxy type
- Set the URL to http://localhost:8191
- Click Test you should see a green success response
- When adding 1337x as an indexer, assign this FlareSolverr proxy to it in the indexer settings
If you already have Jellyfin running as a native TrueNAS app, connecting it to your download folders is quick. Under Storage Configuration → Additional Storage, add these host path entries:
| Mount Path (inside Jellyfin container) | Host Path (on TrueNAS disk) |
|---|---|
| /Movies | /mnt/Pool/Jellyfin/JellyFin/Movies |
| /TV | /mnt/Pool/Jellyfin/JellyFin/TV |
| /Documentary | /mnt/Pool/Jellyfin/JellyFin/Documentary |
When Radarr downloads a movie and moves it to /media/Movies inside its container, that maps directly to /mnt/Pool/Jellyfin/JellyFin_Content/Movies on disk exactly where Jellyfin is looking. Download finishes, Jellyfin picks it up automatically, it appears in your library within minutes.
Written from a real homelab build. Tested on TrueNAS Scale Community Edition · Intel N100 · 8 GB DDR4 · April 2026

No comments:
Please Don't Spam Comment Box !!!!