Docker Community Forums

Share and learn in the Docker community.

Internet through docker wich have vpn connection

Hi,

I have an openvpn connection running on the docker container, on the host I would like to have traffic going through this docker in the browser, and thus through the vpn connection. Any ideas how to configure forwarding or even a bridge?

Thanks!

just to be sure.

From your pc, you want browser traffic to go though this vpn?
If so, you want to create a container with squid (or other proxy software) that uses your vpn container network.

and then, on your pc set http proxy to point to the http proxy you created

Yes, I want the traffic to go through the container and this vpn.
There is no other way without that squid?
What if I can do some kind of dynamic port forwarding in which only 1 port from host will be mapped to all ip and ports accessible from container, once the port forwarding is done I can set the proxy details of my host browser to access only 1 port?