I have a docker container that runs my vpn. Then I have a docker container for my searx instance. Then I forced the searx container to use the vpn container for its network connection.
You'll have to do some research on how to use docker. Forcing a container to go through another container's network using docker.
Yes, I am a software engineer who does fullstack development work, so my background makes it a bit easier to jump into this. But, if you know a few key points to start at, you can research those things and get right to it.
His container is great for torrenting through a VPN. The container is set up to correctly restrict all traffic to go through the VPN tunnel with no leaks.
It can be a bit difficult to set his container up. It supports a few VPNs by default, and for any other he has instructions on how to use OpenVPN and Wireguard via configuration files.
I then run a SearX container as well. In the configuration of that container (in Unraid it uses a GUI, but if you are in command line you are probably using Docker-Compose), I specified the --net=container:binhex-delugevpn option to tell the searx container to bond to the delugevpn container and share it's network. In doing this, searx effectively has the same VPN limits designed into the delugevpn container.
On the delugeVPN container, Binhex has an enironment variable called VPN_INPUT_PORTS where you have to add the searx port so it can get the correct iptables rules from his container's startup script. You also need to add the SearX port to the ports for this container so you can access searX on that port.
Now, I just access SearX through the delugeVPN container just like I would access the Deluge app running in the container. I hit the IP of the host machine with the SearX port and I can now search locally with all my searches being tunneled through my VPN.
Well, easiest way is to use docker in my opinion.
I have a docker container that runs my vpn. Then I have a docker container for my searx instance. Then I forced the searx container to use the vpn container for its network connection.
You'll have to do some research on how to use docker. Forcing a container to go through another container's network using docker.
No worries, I can explain my set up.
Yes, I am a software engineer who does fullstack development work, so my background makes it a bit easier to jump into this. But, if you know a few key points to start at, you can research those things and get right to it.
I'm running docker on an Unraid server at home. On that server, I am running Binhex's delugeVPN container - https://hub.docker.com/r/binhex/arch-delugevpn
His container is great for torrenting through a VPN. The container is set up to correctly restrict all traffic to go through the VPN tunnel with no leaks.
It can be a bit difficult to set his container up. It supports a few VPNs by default, and for any other he has instructions on how to use OpenVPN and Wireguard via configuration files.
I then run a SearX container as well. In the configuration of that container (in Unraid it uses a GUI, but if you are in command line you are probably using Docker-Compose), I specified the --net=container:binhex-delugevpn option to tell the searx container to bond to the delugevpn container and share it's network. In doing this, searx effectively has the same VPN limits designed into the delugevpn container.
On the delugeVPN container, Binhex has an enironment variable called VPN_INPUT_PORTS where you have to add the searx port so it can get the correct iptables rules from his container's startup script. You also need to add the SearX port to the ports for this container so you can access searX on that port.
Binhex has some documentation about how to use VPN_INPUT_PORTS on his Github - https://github.com/binhex/documentation/blob/master/docker/faq/vpn.md
Now, I just access SearX through the delugeVPN container just like I would access the Deluge app running in the container. I hit the IP of the host machine with the SearX port and I can now search locally with all my searches being tunneled through my VPN.