No description, website, or topics provided.
Switch branches/tags
Nothing to show
Clone or download
todorez README: add installation instructions for Windows
Add instructions for installing chameleonsocks on Windows with Docker

Signed-off-by: Todor Minchev <>
Latest commit 2295747 Feb 16, 2017



CHAMELEONSOCKS provides containerized system-wide redsocks-based TCP redirector to generic SOCKS or HTTP proxies. There is a script to aid in the initial setup. This script pulls a tar.gz and loads it as a docker image. It then creates a persistent container that includes your specific proxy/exception information and that persistent container is what is run to provide redirection. Note: This requires root access since the containers need to be run in privileged mode.

NOTE: You will need Internet connectivity to run the installer/upgrade script

Quickstart Instructions

1 . Download the installer and make it executable

https_proxy=<port> wget && chmod 755

2 . Run the installer with the minimum number of required args

https_proxy=<port> PORT=<socksproxyport> PAC_URL= ./ --install

Extended Instructions

1 . Install Docker

Install Docker by following the official instructions for your distribution

2 . Download script

  • Set https_proxy environment variable so you can download the installer
export https_proxy=
  • Execute the following command to download the script and to make it executable
wget && chmod 755

3 . Configure your proxy server and exception rules

  • **Open in your favourite text editor and enter your proxy server (PROXY), proxy server port (PORT) and proxy server type (PROXY_TYPE). supported PROXY_TYPE values are: socks4, socks5, http-connect, http-relay **


    NOTE: The installer provides the following proxy exception rules by default. Requests sent to the following subnets will not be redirected to the proxy.

    **Chameleonsocks provides support for standard PAC or WPAD (Web Proxy Auto Discovery) files. Set the PAC_URL variable in to the URL of your PAC file or WPAD file and the subnet exceptions from the PAC file will be extracted and applied to the chameleonsocks ruleset. Note: ONLY exceptions will be pulled from the PAC_URL file, not the proxy itself. **


  • To add your own proxy exception rules, please append your subnets or individual ip addresses to the default exceptions file and add its absolute path to the EXCEPTIONS variable in

    The default execeptions file can be found here:


4 . Install chameleonsocks

./ --install


4. Upgrade existing chameleonsocks installation

./ --upgrade

5 . Start/Stop chameleonsocks

You can start/stop chameleonsocks in one of two ways:

  • By using the script from the command line

    Start chameleonsocks

    ./ --start

    Stop chameleonsocks

    ./ --stop
  • By using the Docker UI interface

    Install Docker UI

    ./ --install-ui

    Open the following URL in your web browser


    Click the "containers" tab -> Select the "chameleonsocks" container -> Start/Stop the container to enable/disable the proxy

    Uninstall Docker UI

    ./ --uninstall-ui

Check chameleonsocks version

./ --version

Uninstall chameleonsocks

./ --uninstall

NOTE: Instructions for installing chameleonsocks with Docker Toolbox on Windows

./ --install_local chameleonsocks-1.2.tar.gz


If you want to try different combinations because your proxy got moved or because you discover that the XXX proxy is much faster for you, you can quickly do the following:
To get the initial image (where is your https proxy):

https_proxy= ./ --install

You can tell if you have the initial docker image by doing

docker images | grep chameleon

and you should see something like: crops/chameleonsocks VERSION (1.X)...
To try different settings you can either edit the file or prepend environment variables to the call. PAC_URL= ./ --start

To retry do:

 ./ --stop && docker rm chameleonsocks PAC_URL= ./ --start

If you want to stop and start chameleonsocks without using the script after having made the container the first time (which DOES need the script), do:

docker stop chameleonsocks
docker start chameleonsocks

To see what may be wrong, you can do:

docker logs chameleonsocks

Note: if you are using a proxy.pac type autoconfig for your exceptions, it can take some time (?30 seconds?) to get the file and have the container start routing. If you're autoproxy breaks, you need to redo the install and not set the autoproxy (PAC_URL). This will give you just the default exceptions.