0

I have a web app which calls some public APIs which block VPN connection. I would like to route all traffic coming/going to the web app through eth0 and not through the default tun0 which is the interface used when the openvpn client is on.

How can I do this?

3
  • This will very much depend on the type of network manager you're using. If this is the regular Network-Manager", you can just add a route for that IP towards the regular gateway via UI. If you have the CLI only run with "ip route add". "Like ip route add 192.168.200.200/32 dev eth0".
    – boro
    Commented Mar 17 at 0:30
  • But will this directu all traffic to a sever to eth0? I want other apps on the server to route through tun0 and others through eth0
    – bcsta
    Commented Mar 17 at 9:06
  • As that web app will likely not make its own routing decision but tell the OS to do it, it will likely be that way. However, your route defining the API IP (which may not be static) is unlikely to be used by other applications.
    – boro
    Commented Mar 18 at 21:13

0

You must log in to answer this question.

Browse other questions tagged .