Docker CLI Builder
Build Docker commands interactively. Pick an action, choose options, copy the command. Covers run, exec, build, compose, networks, volumes, and system management.
Action
Common Recipes
Ready-to-use Docker commands. Click a recipe to populate the builder, or copy the command directly.
Interactive shell in container
Get a bash/sh shell inside a running container
docker exec -it my-container /bin/sh
Click to load in builder
Build multi-platform image
Build for both amd64 and arm64 architectures
docker build --platform linux/amd64,linux/arm64 -t myapp:latest .
Click to load in builder
Compose up with rebuild
Start services, rebuilding images and removing orphans
docker compose up -d --build --remove-orphans
Click to load in builder
Compose down with cleanup
Stop services and remove volumes and images
docker compose down -v --rmi all --remove-orphans
Click to load in builder
Follow container logs
Stream last 100 lines and follow new output
docker logs -f --tail 100 my-container
Click to load in builder
System prune (full cleanup)
Remove all unused containers, images, networks, and volumes
docker system prune -a --volumes -f
Click to load in builder
List dangling images
Find orphaned images taking up disk space
docker images -f dangling=true
Click to load in builder
Run with resource limits
Container with memory and CPU constraints
docker run -d --name app --memory 512m --cpus 1.5 --restart unless-stopped myapp:latest
Click to load in builder
Container IP address
Get the IP address of a running container
docker inspect -f '{{.NetworkSettings.IPAddress}}' my-containerClick to load in builder
Copy file from container
Extract a file from container to host
docker cp my-container:/app/config.json ./config.json
Create and use a network
Create a bridge network and run containers on it
docker network create --driver bridge my-network
Click to load in builder
Docker CLI Reference
Docker is the most popular container runtime, used to build, ship, and run applications in isolated environments. The docker CLI is how you interact with the Docker daemon to manage containers, images, networks, and volumes.
Most Used Docker Commands
| Command | Purpose | Example |
|---|---|---|
| run | Create and start a container | docker run -d -p 80:80 nginx |
| exec | Run command in container | docker exec -it app /bin/sh |
| build | Build an image | docker build -t myapp:v1 . |
| compose up | Start services | docker compose up -d --build |
| logs | View container logs | docker logs -f --tail 50 app |
| ps | List containers | docker ps -a |
| stop | Stop containers | docker stop app |
| rm | Remove containers | docker rm -f app |
| images | List images | docker images |
| system prune | Clean up everything | docker system prune -a -f |
docker run Flag Guide
-d— Run in background (detached)-it— Interactive with TTY (for shell access)-p host:container— Map ports-v host:container— Mount volumes-e KEY=value— Set environment variables--restart— Restart policy (always, unless-stopped, on-failure)--memory / --cpus— Resource limits--network— Connect to a Docker network
Docker Compose
Docker Compose manages multi-container applications. The CLI integrated into Docker (docker compose) reads a docker-compose.yml and handles the full lifecycle: build, up, down, logs, restart, and more.
Privacy First
All command building happens in your browser. Your container names, image tags, environment variables, and infrastructure details are never sent to any server.