Dockerized HTTP server that serves the mini.py script for on-demand execution via curl.
A lightweight container that serves mini.py over HTTP, enabling:
curl https://yourdomain.com | python3- Fetch and execute immediately- SSH tunnel for local port forwarding:
ssh -L 3000:localhost:3000 user@server
# Build the Docker image
docker build -t mini-script-server .
# Run the container
docker run -d -p 8080:8080 --name script-server mini-script-serverFrom your local machine:
# 1. Establish SSH tunnel (keeps running)
ssh -L 3000:localhost:3000 user@server
# 2. Fetch and run the script
curl https://yourdomain.com | python3The script will execute a reverse proxy on localhost:3000, listening on port 3000.
pythonon your server
mini.py- The minified script (reverse proxy for perplexity.ai)server.py- HTTP server that serves mini.pyDockerfile- Container configuration
- Docker container runs a Python HTTP server on port 8080
- Server responds to GET requests on
/with the mini.py content - curl fetches the script and pipes it to python
- python executes the script (reverse proxy starts on localhost:3000)
This pattern is useful for:
- Self-hosting scripts
- Portable tool distribution
- Executing code through SSH tunnels
- Quick deployments without file transfer