with one click
docker-management
Manage Docker containers, images, volumes, networks, and Compose stacks - lifecycle ops, debugging, cleanup, and Dockerfile optimization.
Menu
Manage Docker containers, images, volumes, networks, and Compose stacks - lifecycle ops, debugging, cleanup, and Dockerfile optimization.
| name | docker-management |
| description | Manage Docker containers, images, volumes, networks, and Compose stacks - lifecycle ops, debugging, cleanup, and Dockerfile optimization. |
| version | 1.0.0 |
| author | hermes-CCC (ported from Hermes Agent by NousResearch) |
| license | MIT |
| metadata | {"hermes":{"tags":["Docker","DevOps","Containers","Infrastructure","Compose"],"related_skills":[]}} |
docker run -d --name myapp -p 8080:80 -v ./data:/data myimage
docker start myapp
docker stop myapp
docker restart myapp
docker rm myapp
-d runs the container in detached mode.--name assigns a stable container name.-p 8080:80 maps host port 8080 to container port 80.-v ./data:/data mounts a host path into the container.docker run -d --name myapp -p 8080:80 -v ./data:/data myimage
Use this pattern when you need:
docker ps
docker ps -a
docker ps shows running containers only.docker ps -a shows all containers including exited ones.docker exec -it myapp bash
bash.sh for slimmer images:docker exec -it myapp sh
Useful checks inside a container:
docker logs -f myapp
-f to follow logs live.--tail 100 to reduce noise when the log is very large.docker images
docker volume ls
docker network ls
docker images helps identify build tags and old layers.docker volume ls helps track stateful storage.docker network ls is useful when debugging Compose service communication.docker build -t myapp:latest .
.dockerignore.FROM python:3.12-slim
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
CMD ["python", "app.py"]
FROM node:22 AS build
WORKDIR /src
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
FROM nginx:alpine
COPY --from=build /src/dist /usr/share/nginx/html
HEALTHCHECK CMD wget -qO- http://localhost/ || exit 1
Example:
HEALTHCHECK --interval=30s --timeout=5s --retries=3 CMD curl -fsS http://localhost:8080/health || exit 1
docker compose up -d
docker compose logs
docker compose down
docker compose up -d starts the stack in the background.docker compose logs shows service logs across the stack.docker compose down stops and removes the stack's containers and network.services:
app:
build: .
ports:
- "8080:8080"
environment:
APP_ENV: development
depends_on:
- redis
redis:
image: redis:7-alpine
docker inspect myapp | jq '.[0].NetworkSettings'
docker inspect to view full JSON metadata.jq to isolate fields that matter.docker stats
docker cp file.txt myapp:/app/
docker cp myapp:/app/output.log ./output.log
docker cp is useful for hot inspection, artifact extraction, and ad hoc debugging.docker cp can unblock investigation quickly.docker system prune -af
docker volume prune
docker system prune -af removes unused containers, networks, dangling images, and build cache aggressively.docker volume prune removes unused volumes.docker run --rm -it --entrypoint sh myimage
docker exec -it myapp env
docker inspect myapp | jq '.[0].Config.Entrypoint, .[0].Config.Cmd'
docker inspect myapp | jq '.[0].Mounts'
docker exec -it myapp sh -c "wget -qO- http://redis:6379 || true"
curl or wget.docker run chains.docker logs -f first when a service does not start cleanly.docker inspect when port mappings or mounts behave unexpectedly.run, start, stop, restart, and rm.docker build -t myapp:latest ..docker exec -it myapp bash, docker logs -f myapp, docker inspect, and docker stats.docker compose up -d, docker compose logs, and docker compose down.docker system prune -af and docker volume prune.Compress conversation context — summarize the current session, extract key decisions and facts, then compact history to free up context window.
Generate insights about your Claude Code usage — what topics you work on most, common patterns, productivity trends.
Route Claude Code work by complexity, risk, and tool needs. Use when deciding how much reasoning depth a task needs, whether to read project memory first, whether the task should be decomposed, and whether the work is lightweight, standard, or investigation-heavy.
Query Polymarket prediction markets for probability data and research insights on real-world events.
Search and retrieve academic papers from arXiv using their free REST API. No API key needed.
Query Base (Ethereum L2) blockchain data — wallet balances, token info, transactions, gas analysis, contract inspection. No API key required.