You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A Docker base image that sets up a transparent proxy stack using Tor and Redsocks with iptables redirection. Import it into your Dockerfile to run any application behind a Tor-anonymized network.
Features
Alpine and Ubuntu variants (Dockerfile.alpine, Dockerfile.ubuntu)
Uses default Tor exit nodes (no country restriction)
Redsocks for transparent TCP proxying
iptables rules redirect all outbound traffic through Tor
Automatic monitoring and restart on failure
Readiness indicator: /tmp/redsocks.ready
Files
File
Description
__setup_proxy.sh
Proxy setup and monitoring script
Dockerfile.alpine
Lightweight Alpine-based image
Dockerfile.ubuntu
Ubuntu-based image
Usage
1. Import into your Dockerfile
# FROM ghcr.io/techroy23/docker-tor-redsocks:alpine# or# FROM ghcr.io/techroy23/docker-tor-redsocks:ubuntuCOPY . /app
RUN chmod +x /app/*.sh
ENTRYPOINT ["/app/your_program.sh"]
# Show Tor logs
docker run -e SHOW_LOGS=true yourimage
Notes
Requires NET_ADMIN and NET_RAW capabilities
Tor runs as dedicated toruser
Tor uses its default exit nodes (no country restriction)
About
This project provides a Docker base image that automatically sets up a transparent proxy stack using Tor and Redsocks, with iptables redirection. It is designed to be imported into your own Dockerfile, so you can run your application behind a monitored global proxy.