i am running Debian 12 and i have 2 ethernet interfaces:
enp6s10: 192.168.10.10/24 with gw: 192.168.10.1
enp6s20: 192.168.20.20/24 without gateway
behind each interface there is a DSL connection.
I would like to have a list of URLs that need to be routed through the 2nd interface that does not have a default gw.
i am thinking of a proxy, but i am not familiar with the config.
proxy ? to route based on URL
-
- Debian Developer
- Posts: 571
- Joined: 2022-07-12 14:10
- Has thanked: 2 times
- Been thanked: 114 times
Re: proxy ? to route based on URL
If you want to have two connections to internet, you need multiple routing tables. As far as I know, this is not supported by ifupdown, NetworkManager of systemd-networkd. This means you need to do quite a lot of manual configuration explained in https://tldp.org/HOWTO/Adv-Routing-HOWTO/
If somebody knows a network framework that supports multiple routing tables, let me know
After you have configured multiple routing tables you need configure your browser to use a proxy.pac file (proxy automatic configuration) that uses DIRECT by default and PROXY for specific URLs. That PROXY directive needs to point to localhost where you need to run some HTTP proxy program like squid and configure it to use the second internet connection.
If somebody knows a network framework that supports multiple routing tables, let me know
After you have configured multiple routing tables you need configure your browser to use a proxy.pac file (proxy automatic configuration) that uses DIRECT by default and PROXY for specific URLs. That PROXY directive needs to point to localhost where you need to run some HTTP proxy program like squid and configure it to use the second internet connection.
-
- Global Moderator
- Posts: 3950
- Joined: 2014-07-20 18:12
- Location: Europe
- Has thanked: 109 times
- Been thanked: 518 times
Re: proxy ? to route based on URL
Can you explain what you are really supposed to do?atux_null wrote: ↑2024-10-21 17:28 i am running Debian 12 and i have 2 ethernet interfaces:
enp6s10: 192.168.10.10/24 with gw: 192.168.10.1
enp6s20: 192.168.20.20/24 without gateway
behind each interface there is a DSL connection.
I would like to have a list of URLs that need to be routed through the 2nd interface that does not have a default gw.
i am thinking of a proxy, but i am not familiar with the config.