Lets create a server in whatever your availability zone your VPS is in.

For me, that's uk2 cloud. For you, that may be something different.

Steps below will show the basic setup and configuration of TinyProxy.

  1. Lounch your instance.

  2. If amazon, you should configure security groups to open desired TCP ports.

  3. Connect via ssh to your instance:

  4. Install TinyProxy

    `sudo apt-get install tinyproxy`
    
  5. Edit /etc/tinyproxy.conf using the editor of your choice, i usually use nano:

    `sudo nano /etc/tinyproxy.conf`
    
  6. Make sure that /etc/tinyproxy.conf file contains the lines Port 8888 and Allow xxx.xxx.xxx.xxxx where xxx.xxx.xxx.xxxx is your IP address. (Check your IP address by running curl ipecho.net/plain from another Terminal window, or use WhatIsMyIP.com). Checkout https://www.justinmccandless.com/post/set-up-tinyproxy-in-ubuntu for some memmory saving tips.

  7. So, 3128 is the port that we'll use to connect to localhost. And it will be forwarded to port 8888 of our VPS instance.

ssh -f -C -q -N -L 3128:localhost:8888 -i /path/to/yourkey.pem [email protected]

or

sshpass -p 'yourpassword' ssh -f -C -q -N -L 3128:localhost:8888 [email protected]

  • -f: Forks the process to the background

  • -C: Compresses the data before sending it

  • -q: Uses quiet mode

  • -N: Tells SSH that no command will be sent once the tunnel is up

    1. Change your browser settings (or any other program that should use proxy or even operating system's proxy settings).

Make the host: localhost

Set the proxy port to: 3128

 9. Verify that this went well by running`curl ipecho.net/plain`from another Terminal window, or by using [WhatIsMyIP.com](/WhatIsMyIP.com).

Your IP should match that of your VPS.

results matching ""

    No results matching ""