So I have tor installed and have it enabled with systemctl, so tor.service starts on boot and I can automatically just configure SOCKS5 proxies to 127.0.0.1:9050.
Now, tor has a few minor annoyances. Since it's well known, some sites block tor exit nodes. I came up with a solution. I bought a VPS and use an SSH tunnel to it as a SOCKS5 proxy. If I start the tunnel with the torsocks command, then the actual route looks like:
me > tor network > VPS > internet
The command I use is a one liner:
torsocks sshpass -p password ssh -p 69 -D 9040 user@IP
And it works fine. It launches a terminal and as long as I keep that terminal open, it worked.
Now what I want is for it to launch on system boot and run in the background. I tried using nohup while booted but it didn't work. It just didn't start the proxy. I tried systemctl, I tried gnome's .gnomerc, everything.
My current solution:
[me@me ~]$ echo 'torsocks sshpass -p password ssh -p 69 -D 9040 user@IP' > proxy [me@me ~]$ sudo chmod +x proxy
And then whenever I need it I just do: