Jump to content
Not connected, Your IP: 216.73.217.75
traerin

ANSWERED Gluetun + qbittorrent + port forwarding not working

Recommended Posts

Hello everyone,

Before posting, i've checked different topics on the same issue (Here, here, here, here), but I didn't find any solution.

Before, I was on Win11 with the AirVPN app, and port forwarding was working.
I switchted my mini server on Proxmox, and put qbittorrent behind gluetun.

It works in a way, as I can download and upload, even if the DHT number is half what it was on Win11.

But the main issue is that I'm struggling accessing my qbittorrent Web UI from outside.

On the AirVPN port forwarding admin, when I test open my 2 ports (one for download, one for the web ui), I have connection timeout.

Port 37596 is for download.
Port 30306 is for Web UI.


Here is my docker compose :

services:
  gluetun:
    image: qmcgaw/gluetun
    container_name: gluetun
    cap_add:
      - NET_ADMIN
    devices:
      - /dev/net/tun:/dev/net/tun
    volumes:
      - /opt/docker/config/gluetun:/gluetun
    ports:
      - 37596:37596/tcp
      - 37596:37596/udp
      - 30306:30306
    environment:
      - VPN_SERVICE_PROVIDER=airvpn
      - VPN_TYPE=wireguard
      
      - WIREGUARD_PRIVATE_KEY=***
      - WIREGUARD_PRESHARED_KEY=***
      - WIREGUARD_ADDRESSES=***/32
      - WIREGUARD_IMPLEMENTATION=userspace
      - WIREGUARD_MTU=1320
      - WIREGUARD_PORT=1637
      
      - SERVER_COUNTRIES=Netherlands
      - PORT_FORWARDED=37596,30306
      - FIREWALL_OUTBOUND_SUBNETS=192.168.1.0/24
      - FIREWALL_INPUT_PORTS=30306,37596
      - VPN_PORT_FORWARDING_LISTENING_PORTS=30306,37596
      - DNS_UPSTREAM_RESOLVER_TYPE=plain
      - DNS_UPSTREAM_PLAIN_ADDRESSES=***:53
      - UPDATER_PERIOD=24h

    healthcheck:
         test: ["NONE"]
    restart: always

  qbittorrent:
    image: lscr.io/linuxserver/qbittorrent:latest
    container_name: qbittorrent
    network_mode: "service:gluetun"
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/Paris
      - WEBUI_PORT=30306
      - TORRENTING_PORT=37596
    volumes:
      - /opt/docker/config/qbittorrent/qBittorrent:/config
      - /mnt/pve/NAS:/NAS
    restart: always
If someone has an idea, it would be delightful :)

Thank you :)
 

Share this post


Link to post
2 hours ago, traerin said:

If someone has an idea, it would be delightful :)


Hello!

The FIREWALL_VPN_INPUT_PORTS environment variable is not set, unless you set it in your GlueTun invocation command, therefore the incoming (unsolicited) packets on the tunnel VPN interface are dropped. See also:
https://github.com/qdm12/gluetun-wiki/blob/main/setup/options/firewall.md

Note that the other variables related to firewall and inbound ports that you set on the compose file do not affect the firewall rules for the VPN interface:
  • FIREWALL_INPUT_PORTS pertains to the default interface. You might like to delete the related line as we bet you do not want your p2p software to reply to incoming packets from the Internet and disclose your real IP address
  • VPN_PORT_FORWARDING_LISTENING_PORTS has a totally different purpose, it re-directs a port to a custom localhost port of your choosing and will break p2p software ability to receive incoming packets. Do not use this variable with torrent clients, or any other software that publicly announces its port, as that software would not be aware of the publicly visible port and would be announcing the private port instead. Delete that line and read the documentation here for more details: https://github.com/qdm12/gluetun-wiki/blob/main/setup/advanced/vpn-port-forwarding.md
As a side note for you and all the readers using GlueTun: read GlueTun's good documentation if you haven't already done so!

Kind regards
 

Share this post


Link to post
Posted ... (edited)

THANK YOU ITS WORKING

Edited ... by traerin
I found the issue, that was a f***** typo....

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Security Check
    Play CAPTCHA Audio
    Refresh Image

×
×
  • Create New...