Docker Essentials
Version: 24.xPublished: 2026-01-16docker/core
Essential Docker commands for container management.
Images
| Example | Description |
|---|---|
| Pull image Download an image from a registry. |
| List images Show all local images. |
| Build image Build image from Dockerfile in current directory. |
| Remove image Delete a local image. |
| Prune unused Remove all unused images. |
Containers
| Example | Description |
|---|---|
| Run Start a container in detached mode with port mapping. |
| List running Show running containers. |
| List all Show all containers including stopped. |
| Stop Gracefully stop a running container. |
| Remove Delete a stopped container. |
| Logs Follow container logs in real-time. |
Exec & Debug
| Example | Description |
|---|---|
| Shell into container Open interactive shell in running container. |
| Run command Execute a command in a running container. |
| Inspect View detailed container configuration as JSON. |
| Stats Live resource usage for all containers. |
Volumes
| Example | Description |
|---|---|
| Create volume Create a named volume for persistent data. |
| List volumes Show all volumes. |
| Mount volume Attach a volume to a container. |
| Bind mount Mount host directory into container. |
Networks
| Example | Description |
|---|---|
| List networks Show all Docker networks. |
| Create network Create a custom bridge network. |
| Connect container Add a container to a network. |
Cleanup
| Example | Description |
|---|---|
| Remove stopped containers Delete all stopped containers. |
| System prune Remove all unused data (images, containers, volumes). |
| Disk usage Show Docker disk usage summary. |