Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fylein/squid
Simple Squid setup
https://github.com/fylein/squid
Last synced: about 2 hours ago
JSON representation
Simple Squid setup
- Host: GitHub
- URL: https://github.com/fylein/squid
- Owner: fylein
- License: mit
- Created: 2020-09-10T02:26:42.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2023-11-02T11:24:08.000Z (about 1 year ago)
- Last Synced: 2025-01-01T12:39:15.153Z (5 days ago)
- Language: Shell
- Size: 7.81 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Introduction
This repo builds a docker image to run a squid proxy with basic authentication. The configurations are very lax - so
please do not use it for any security-sensitive deployments. This is meant for development use only.This was inspired by this [project](https://hub.docker.com/r/sameersbn/squid).
# Build
```bash
docker build -t squid .
```## Running
First time around, create a directory in the host where all the log files will go
```bash
mkdir ~/squid
```Start Squid using this command.
```bash
docker run --name=squid --rm -d -p 8981:3128 -v ~/squid/:/var/cache/squid/ squid
```Cmd to test if the proxy is working.
```bash
curl --proxy 'http://squid:squid@:8981' 'https://httpbin.org/ip'
```You should start seeing access logs in ~/squid directory.
## Change default password
You can modify the default password using following steps
* Re-create passwd file using htpasswd
```bash
htpasswd -B -c squid.passwd squid
```* Pass the new passwd file as volume to docker container
```bash
docker run --name=squid --rm -d -p 8981:3128 -v ~/squid/:/var/cache/squid/ -v ./squid.passwd:/etc/squid/squid.passwd squid```
## Debugging
```bash
docker run -it --entrypoint=/bin/bash squid
```