docker-management

Manage Docker containers, images, volumes, networks, and Compose stacks via CLI commands.

Updated Jun 7, 2026
One-click install
npx skills add https://github.com/Chensihakniroth/ANAKOT-AGENT --skill docker-management-chensihakniroth
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: docker-management
Source: https://github.com/Chensihakniroth/ANAKOT-AGENT/tree/main/optional-skills/devops/docker-management
Command: npx skills add https://github.com/Chensihakniroth/ANAKOT-AGENT --skill docker-management-chensihakniroth

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Managing Docker environments involves remembering dozens of CLI commands across containers, images, volumes, networks, and Compose stacks, and mistakes like aggressive pruning can destroy data. This Skill provides structured, safe procedures for the full Docker lifecycle. ## Core Features & Use Cases - Container Lifecycle Operations: Run, stop, restart, inspect, and shell into containers with correct flags for ports, volumes, environment variables, and resource limits. - Compose Stack Management: Start, monitor, debug, and validate multi-service stacks with healthchecks and dependency ordering. - Safe Cleanup & Debugging: Diagnose disk usage before pruning, analyze logs and exit codes, and resolve common pitfalls like port conflicts and permission errors. - Use Case: A developer's container keeps crashing on startup. Use this Skill to inspect logs, identify the exit code cause, test interactively with an overridden entrypoint, and fix the Dockerfile with multi-stage build optimizations. ## Quick Start Use the docker-management skill to check why my api container keeps exiting and show me its recent logs.

Frequently Asked Questions about docker-management

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug a Docker container that exits immediately?▼

Check the container logs with docker logs NAME to find the crash cause, then run docker run -it --entrypoint /bin/sh IMAGE to explore the image interactively. Immediate exits usually mean the main process finished or crashed on startup.

How to free up Docker disk space safely?▼

Start with docker system df to see what is using space, then run targeted cleanup: docker container prune for stopped containers, docker image prune for dangling images, and docker volume prune for unused volumes. Avoid docker system prune -a --volumes unless you confirm named volume data is disposable.

Does Docker Compose come with modern Docker installations?▼

Yes, Docker Compose v2 is included with modern Docker installations as a plugin, invoked as docker compose rather than the older docker-compose binary. Verify with docker compose version.

Why can't I connect to my Docker container from the host?▼

The application inside the container is likely binding to 127.0.0.1, which is unreachable externally. It must bind to 0.0.0.0, and you need a correct -p host:container port mapping on docker run.

How do I reduce Docker image size?▼

Use multi-stage builds to separate build and runtime environments, pick slim or alpine base images like python:3.12-slim, combine RUN commands to reduce layers, and add a .dockerignore file excluding node_modules and .git.