I run OpenVPN client in a docker container to establish a tunnel to TorGuard. I then setup docker containers to use that OpenVPN container as their network. That all works fine and outbound connections from any of those docker containers show as coming from the TorGuard VPN server and not from my own server.
I'm trying to sort out why BitTorrent won't work properly - it says that my incoming port is blocked.
In TorGuard, I have a dedicated IP, and a dedicated port all setup, so the TorGuard VPN server should be passing traffic to that ip:port on to my VPN client. Somewhere, it's getting blocked and doing a port-scan just gets a timeout.
Do I need to do something in the VPN config to pass on this port to the docker container/internal network somehow? Or how can I see what is blocking the port?
Any ideas? Thanks!
Here's my vpn.conf:
Code: Select all
client
dev tun
proto udp
remote <DEDICATED-IP> 995
remote-cert-tls server
auth SHA1
resolv-retry infinite
nobind
cipher AES-256-CBC
#cipher AES-128-CBC
auth-user-pass openvpn-credentials.txt
#compress
ncp-disable
#tun-mtu-extra 32
inactive 3600
ping 10
ping-exit 60
up /vpn/ll_up.sh
<ca>
-----BEGIN CERTIFICATE-----
blahblahblah-----END CERTIFICATE-----
</ca>
Code: Select all
openvpn:
image: dperson/openvpn-client
container_name: openvpn
privileged: true
volumes:
- /data/appdata/docker/openvpn/:/vpn
- /dev/net:/dev/net:z
restart: always
ports:
- 51866:51866 # Incoming BitTorrent port
- 51866:51866/udp # Incoming BitTorrent port
networks:
- default
environment:
- TZ=Europe/London
cap_add:
- net_admin
tmpfs:
- /run
- /tmp
command: "-r 192.168.1.0/24 -f ''"
healthcheck:
test: ["CMD", "pgrep", "openvpn"]
interval: 1m30s
timeout: 10s
retries: 3
transmission:
image: ghcr.io/linuxserver/transmission
container_name: transmission
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=Europe/London
volumes:
- /data/appdata/docker/transmission:/config
- /data/downloads:/data/downloads
- /data/downloads:/downloads
- /data2/downloads:/data2/downloads
- /data/appdata/transmission/auto:/watch
- /data/downloads/incomplete/transmission:/data/incomplete/transmission
depends_on:
- openvpn
network_mode: service:openvpn
restart: unless-stopped
healthcheck:
test: ["CMD", "ping", "-c", "1", "-W", "5", "8.8.8.8"]
interval: 1m30s
timeout: 10s
retries: 3