Discussion Run some containers through a VPN docker

noname

Junior Member
Original poster
Local time
5:42 AM
Jan 18, 2019
23
2
PG Version
8.1.2
Server Type
Local - Dedicated Server
Does anyone have an idiots guide to how I can have some containers (deluge specifically) through a VPN but not everything else? As I am sure many of you know setting up remote access to a plex server through a VPN doesn't work without some monumental feats. As such currently I run my download client on a different machine. Since finding PG I want to be able to put all things together in the same place. Actually what may work better...

If I had all containers on the same ubuntu 18.04 machine: heimdall, sonarr, radarr, ombit. tautulli, portainer, jackett, PIA (would need to create my own container for this) and plex

I would want all traffic to go through the PIA container with the exception of PLEX

Is this even possible?
 

noname

Junior Member
Original poster
Local time
5:42 AM
Jan 18, 2019
23
2
That seems to be exactly what I am looking for. Unfortunately I chose PG because I don't know a whole lot about how to set this stuff up. Is there a guide somewhere that will assist/walk me through the process of creating this container and integrating it with PG? I would like it to be able to be used in traefik? Is there a request place somewhere? Lets have this image added to PG?
 

artiume

Full Member
Local time
8:42 AM
Mar 19, 2018
31
10
docker run --cap-add=NET_ADMIN --device=/dev/net/tun -d \
-v /:/data \
-v /etc/localtime:/etc/localtime:ro \
-e OPENVPN_PROVIDER=PIA \
-e OPENVPN_CONFIG=CA\ Toronto \
-e OPENVPN_USERNAME=user \
-e OPENVPN_PASSWORD=pass \
-e WEBPROXY_ENABLED=false \
-e LOCAL_NETWORK=192.168.1.0/24 \
-l traefik.port=9091 \
-l traefik.frontend.rule=Host:trans.domain.com \
-l traefik.docker.network=plexguide \
-l traefik.backend=trans \
-l traefik.enable=true \
--network plexguide
--log-driver json-file \
--log-opt max-size=10m \
-p 9091:9091 \
haugene/transmission-openvpn


i haven't tested it beyond verifying it builds. i'll try and encorporate it into my stack but i'm running an armhf cluster swarm so things can get aweebit hairy when getting the network to play along.
 

Sejrup

Respected Member
Local time
2:42 PM
Jan 11, 2019
91
32
Above works perfect, but I am unable to add Transmission as a downloader in Sonarr. Do you happen to know how to set the "label" in Traefik so that I can just write trans and port, like I would for nzbget ro sabnzbd? I thought -l traefik.backend=trans would do that, but it doesn't seem to work.
Cheers
 

noname

Junior Member
Original poster
Local time
5:42 AM
Jan 18, 2019
23
2
docker run --cap-add=NET_ADMIN --device=/dev/net/tun -d \
-v /:/data \
-v /etc/localtime:/etc/localtime:ro \
-e OPENVPN_PROVIDER=PIA \
-e OPENVPN_CONFIG=CA\ Toronto \
-e OPENVPN_USERNAME=user \
-e OPENVPN_PASSWORD=pass \
-e WEBPROXY_ENABLED=false \
-e LOCAL_NETWORK=192.168.1.0/24 \
-l traefik.port=9091 \
-l traefik.frontend.rule=Host:trans.domain.com \
-l traefik.docker.network=plexguide \
-l traefik.backend=trans \
-l traefik.enable=true \
--network plexguide
--log-driver json-file \
--log-opt max-size=10m \
-p 9091:9091 \
haugene/transmission-openvpn


i haven't tested it beyond verifying it builds. i'll try and encorporate it into my stack but i'm running an armhf cluster swarm so things can get aweebit hairy when getting the network to play along.
I don't know what this is...
Is the first line a command and then I put the rest in a file and save? Do I paste the whole thing at once to the command prompt and press enter? Sorry, really new to docker stuff. That's why PG is great though!
 

Sejrup

Respected Member
Local time
2:42 PM
Jan 11, 2019
91
32
short answer, yes. I needed to move the line --network plexguide to the top though.

docker run --cap-add=NET_ADMIN --device=/dev/net/tun --network plexguide -d \
 

DrgnFyre

Respected Member
Local time
7:42 AM
Dec 25, 2018
65
7
Nebraska, US
once you've deployed this, how do you connect to it with another docker container like sonarr or radarr? I've tried using 'trans' as the connection string (trans.tld.com works to get me to the transmission client) but they come back with can't connect or can't resolve.
 

artiume

Full Member
Local time
8:42 AM
Mar 19, 2018
31
10
To connect one docker container to another (such as a VPN), you have to use network_mode: container:containername

This is a little beyond the scope though. If this is still wanted, I could make a fork in PG to help everyone out.
 

artiume

Full Member
Local time
8:42 AM
Mar 19, 2018
31
10
What part are you getting lost at? A lot of this is beyond the scope of PG
 

Create an account or login to comment

You must be a member in order to leave a comment

Create account

Create an account on our community. It's easy!

Log in

Already have an account? Log in here.


Maintenance Donations

Recommend NewsGroups

      Up To a 58% Discount!

Trending