docker

A guide for managing Docker, a system that runs applications in isolated containers. It covers containers, the packaged images they run from, saved data volumes, networks, and Compose groups of related containers.

In plain words
What is it for?
Build, run, stop, restart, inspect, and debug containers; manage images, volumes, and networks; run Compose services; view logs; and apply resource or restart settings.
Why use it?
It brings common Docker setup, inspection, troubleshooting, and cleanup tasks into one reference.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/bug-ops/zeph/docker
Any agent
npx skills add bug-ops/zeph --skill docker
Clone the repo
git clone --depth 1 https://github.com/bug-ops/zeph

Made for: Claude Code, Codex.

Per session 97 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,338 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00097 $0.02338
Opus 5 $0.00048 $0.01169
Sonnet 5 $0.00019 $0.00468
Haiku 4.5 $0.00010 $0.00234

Measured 2d ago against content hash b363d6ae3bae, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

docker scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

--health-cmd="curl -f http://localhost/ || exit 1" \
.zeph/skills/docker/SKILL.md · 487 lines

How it starts

The opening of the file, as written. The whole thing — 487 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Docker Operations

Container Lifecycle

List containers

# Running containers
docker ps

# All containers (including stopped)
docker ps -a

# Quiet mode (IDs only)
docker ps -q

# Filter by status
docker ps -f "status=exited"

# Custom format
docker ps --format "table {{.ID}}\t{{.Names}}\t{{.Status}}\t{{.Ports}}"

Create and run

# Run in foreground
docker run IMAGE

# Run detached with a name
docker run -d --name NAME IMAGE

# Run with port mapping (host:container)
docker run -d -p 8080:80 IMAGE

# Run with environment variables
docker run -d -e KEY=VALUE -e KEY2=VALUE2 IMAGE

# Run with env file
docker run -d --env-file .env IMAGE

# Run interactive shell
docker run -it IMAGE /bin/bash

# Run with auto-remove on exit
docker run --rm IMAGE

# Run with volume mount (bind mount)
docker run -d -v /host/path:/container/path IMAGE

# Run with named volume
docker run -d -v myvolume:/data IMAGE

# Run with read-only filesystem
docker run --read-only IMAGE

# Run with resource limits
docker run -d --memory=512m --cpus=1.5 IMAGE

# Run with restart policy
docker run -d --restart=unless-stopped IMAGE

# Run on a specific network
docker run -d --network=mynet IMAGE

# Run with health check
docker run -d \
  --health-cmd="curl -f http://localhost/ || exit 1" \
  --health-interval=30s \
  --health-timeout=10s \
  --health-retries=3 \
  IMAGE

Stop, start, restart, remove

# Stop gracefully (SIGTERM, then SIGKILL after timeout)
docker stop CONTAINER

# Stop with custom timeout (seconds)
docker stop -t 30 CONTAINER

# Start a stopped container
docker start CONTAINER

# Restart
docker restart CONTAINER

# Kill immediately (SIGKILL)
docker kill CONTAINER

# Remove stopped container
docker rm CONTAINER

# Force remove running container
docker rm -f CONTAINER

# Remove all stopped containers
docker container prune -f

Execute commands in running containers

# Run command
docker exec CONTAINER COMMAND

# Interactive shell
docker exec -it CONTAINER /bin/bash

# Run as specific user
docker exec -u root CONTAINER COMMAND

# Set environment variable
docker exec -e VAR=value CONTAINER COMMAND

# Set working directory
docker exec -w /app CONTAINER COMMAND

Read the full file on GitHub · 487 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 487 lines · 97 tokens per session scan A b363d6ae3bae

Subscribe to this mod's changes

docker is a skill published in the GitHub repository bug-ops/zeph (57 stars, last pushed 7d ago), licensed MIT. It adds 97 tokens to every session and 2,338 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.