Self-host your own SOCKS5 Proxy Server with Docker

With a cheap Virtual Machine and a little Docker fairy dust you too can self-host and run your own SOCKS5 proxy server. I use it for occasional web page scraping and getting around numerous restrictions based on my location.

With a cheap Virtual Machine and a little Docker fairy dust you too can self-host and run your own SOCKS5 proxy server. I use it for occasional web page scraping and getting around numerous restrictions based on my location.


Requirements

Docker is fantastic whenever possible, simply because it saves the hassle of dependency management.

Setting up the SOCKS5 service

I like docker-compose because it gives me repeatable, self-documented, and validated configurations.

There is a simple Docker image from this repo:

docker-compose.yml

version: '3'

services:

    socks5:
        image: serjs/go-socks5-proxy
        container_name: socks5
        restart: always
        ports:
            - 1080:1080

A simple docker-compose up -d and it is up and running. Since I use ZeroTier as my VPN, there is no need to open the ports on the firewall to the outside world.

Setting up your browser to use the proxy

Yeah, so that is a separate post because it is a little too complicated when going "soup to nuts."

Use FoxyProxy to Quickly change your Browser’s SOCKS5 Settings
A quick 10-step walkthrough to change your browsers proxy settings with the FoxyProxy browser extension.

Final Thoughts

This post is a little too short to really have final thgouths. So that's it. Spin up a docker image with the right ports exposed, connect your browser/clients to the proxy end-points, and Bob's your uncle.

Subscribe to Candid and colorful thoughts on enterprise readiness

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
jamie@example.com
Subscribe