https://github.com/hectorm/docker-proxy
Traefik image pre-configured to act as a transparent proxy.
https://github.com/hectorm/docker-proxy
Last synced: 9 months ago
JSON representation
Traefik image pre-configured to act as a transparent proxy.
- Host: GitHub
- URL: https://github.com/hectorm/docker-proxy
- Owner: hectorm
- License: mit
- Created: 2023-07-12T14:53:39.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2025-03-03T22:15:50.000Z (over 1 year ago)
- Last Synced: 2025-03-30T06:28:00.220Z (over 1 year ago)
- Language: Dockerfile
- Homepage: https://hub.docker.com/r/hectorm/proxy
- Size: 220 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Transparent proxy for Docker containers
Traefik image pre-configured to act as a transparent proxy. It allows containers without direct Internet access to connect to specific hosts.
## Usage
```yaml
services:
yourapp:
image: "registry.example.com/yourapp:latest"
networks:
private:
proxy:
image: "docker.io/hectorm/proxy:v3"
networks:
public:
private:
aliases:
- "example.com"
- "example.net"
- "smtp.example.com"
- "postgres.example.com"
- "mysql.example.com"
environment:
PROXY_UPSTREAMS: |
example.com:443:tls
example.net:443:tls
smtp.example.com:465:tls
smtp.example.com:587:tcp
postgres.example.com:5432:tls
mysql.example.com:3306:tcp
networks:
public:
internal: false
private:
internal: true
```
> [!NOTE]
> For the `tls` kind, the proxy inspects the SNI to determine the target host. For other kinds, the proxy does not inspect the traffic and will throw an error if the same protocol and port combination is used for multiple hosts.