Jump to content
absent

Docker "Network Type" of another container

1 post in this topic Last Reply

Recommended Posts

Would be great to be able to specify a different docker container for the "Network Type" natively, where a docker container is using:

--cap-add=NET_ADMIN --device /dev/net/tun

config-vpn.thumb.png.6b1b82ad62ea4107744e70618eded977.png

 

A use case for this is as follows:

I have a VPN Client Docker (dperson/openvpn-client) [called "vpn"] that's permanently connected to my VPN provider (PIA in my case)

I then have 2 dockers which tunnel their network through that container (jackett and qbittorrent)

 

config-client.thumb.png.90785015491ed5da9aa0723a46e56227.png

 

At present I have come up with a bit of a hack after lots of messing around where I set the 2 dependent containers Network Types to "None", then add into "Extra Parameters":

--net=container:vpn

Hopefully this could include a UI update that would use the containers name instead of the UID too

main-screen.thumb.png.d315873ec53854e9fb883d7597ebc128.png

 

 

I know what I have done is probably massively hacky, but I couldn't get it to work how I desired any other way. I did not want the VPN at the server level, as that interferes with things like Plex remove services, etc. And hey, I'm a developer; sometimes the solution is just "I need to get this to work, It don't need to be pretty".

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now