📡 You're offline — showing cached content
New version available!
Quick Access
Tutorials Docker Container Inspection

Container Inspection

4 min read
Inspect container state, copy files, check resource stats, and save/load images as tarballs.

Inspecting Containers

docker inspect mycontainer
docker inspect --format={{.State.Status}} mycontainer
docker inspect --format={{.NetworkSettings.IPAddress}} mycontainer

docker top mycontainer        # running processes
docker stats mycontainer      # resource usage

# Copy files to/from container
docker cp mycontainer:/app/error.log ./error.log
docker cp ./config.json mycontainer:/app/

# Save / load images
docker save myapp:1.0 | gzip > myapp.tar.gz
docker load < myapp.tar.gz