This Squid Docker Image is based on Alpine Linux. Squid is compilated with the following features:
- Traffic shaping or bandwidth limiting (--enable-delay-pools)
- HTTP interception (--enable-linux-netfilter)
- Basic and digest HTTP authentication schemes supported (--enable-auth)
Run this container with the following command:
sudo docker run --name squid01 -d -p 3128:3128/tcp --restart=always dmachard/squid:latest
Testing squid container
$ export http_proxy=127.0.0.1:3128
$ export https_proxy=127.0.0.1:3128
$ wget http://example.com
--2021-10-13 15:59:51-- http://example.com/
Connecting to 127.0.0.1:3128... connected.
Proxy request sent, awaiting response... 200 OK
Length: 1256 (1.2K) [text/html]
Saving to: ‘index.html
You can run this image and provide your own squid configuration like that:
sudo docker run --name squid01 -d -p 3128:3128/tcp -v $PWD/mysquid.conf:/opt/squid/etc/squid.conf \
dmachard/squid:latest