/engineering-advanced-skills:docker-developmentfrom engineering-advanced-skills
Analyzes Dockerfiles and Compose files for security issues, image size, cache optimization, and config problems with CI-ready exit codes.
Ships in engineering-advanced-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
The agent reviews Dockerfiles and Compose files the way a careful platform engineer would: security first (root user, secrets, privileged containers, floating tags), then image size and build-cache order, then operability (health checks, restart policies, resource limits). The two analyzers catch the mechanical issues so the review can focus on the design.
Before running the analysis, settle the inputs below. When one is missing or vague and would change the result, ask about it; when it wouldn't, use a sensible default and say which one you used.
--file and which tool runs).--security-only/--check-ports).--format json and whether findings gate a pipeline).Ask about the two or three inputs that matter most for this request, not the whole list. If the user wants a result straight away, produce it and state your assumptions at the top.
dockerfile_analyzer.py and the Compose file with compose_validator.py.ENV/environment, root user, privileged mode, host port conflicts. Then floating tags, then layer and cache order, then health checks and limits.USER, dependency files copied before source.docker build and docker compose config to confirm the files still work. The analyzers read text; only a build proves the image.python3 scripts/dockerfile_analyzer.py --file examples/Dockerfile.sample # latest tag, ENV secret, root (exit 1)
python3 scripts/compose_validator.py --file examples/docker-compose.sample.yml # port clash, privileged, literal passwords (exit 1)
python3 scripts/compose_validator.py --file examples/docker-compose.sound.yml # clean (exit 0)
python3 scripts/compose_validator.py --file examples/docker-compose.sample.yml --check-ports # port check only
In CI, write one report per tool (two JSON documents in one file is not valid JSON) and gate on the exit codes:
python3 scripts/dockerfile_analyzer.py --file Dockerfile --format json > dockerfile-report.json
python3 scripts/compose_validator.py --file docker-compose.yml --format json > compose-report.json
| Tool | Checks | Key flags | Exit codes |
|---|---|---|---|
dockerfile_analyzer.py | Root user, latest/untagged base, secrets in ENV/ARG, oversized base images, runs of consecutive RUN layers, missing --no-install-recommends, cache-breaking COPY . before installs, single-stage builds with many steps, missing HEALTHCHECK, missing .dockerignore next to the Dockerfile | --file, --security-only, `--format text | json` |
compose_validator.py | Structure, circular depends_on, host port conflicts, Docker socket and sensitive mounts, privileged and host network mode, floating image tags, literal passwords/secrets/tokens in environment, restart policy, resource limits | --file, --check-ports (runs only the port check), `--format text | json` |
Mistake: Treating a clean analyzer run as a container security review. Why it happens: Zero findings looks like approval. Instead: The rules are text checks. Scan the built image for CVEs (Trivy, Grype or the registry's scanner) and review runtime privileges separately.
Mistake: "Fixing" a secret finding by moving the value to a build ARG.
Why it happens: The warning disappears from ENV.
Instead: Build args are stored in image history. Use BuildKit secrets (RUN --mount=type=secret) for build-time secrets and runtime environment or secret stores for the rest.
Mistake: Switching every base image to Alpine for size.
Why it happens: Smaller looks strictly better.
Instead: musl breaks some native wheels and binaries. Prefer -slim or distroless when Alpine causes rebuilds from source, and confirm with a test build.
scripts/dockerfile_analyzer.py, scripts/compose_validator.py — the analyzers.examples/Dockerfile.sample, examples/docker-compose.sample.yml (deliberately flawed), examples/docker-compose.sound.yml (passes).In Scope:
dockerfile_analyzer.py: layer count, multi-stage use, running as root, latest tags, secrets in the file, base image choice and cache-breaking instruction order, with --security-only for a narrower reportcompose_validator.py: file structure, circular depends_on chains, duplicate host port bindings, volume mounts, security settings and best practices such as restart policies and resource limitsOut of Scope:
engineering/dependency-auditor/)engineering/kubernetes-operator/ and engineering/helm-chart-builder/)engineering/devops-workflow-engineer/)Important Caveats:
extends, include and variable substitution may not be read correctly.compose_validator.py checks one file per run. Port conflicts or overrides spread across several Compose files are not detected.alpine, slim or distroless suits an image depends on its libraries and needs a test build.examples/Dockerfile.sample (opens in a new tab)examples/docker-compose.sample.yml (opens in a new tab)examples/docker-compose.sound.yml (opens in a new tab)references/docker-best-practices.md (opens in a new tab)scripts/compose_validator.py (opens in a new tab)scripts/dockerfile_analyzer.py (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
100 skills in this plugin
/a11y-auditStatic WCAG scan of HTML files (alt text, headings, labels, ARIA, lang, landmarks) and colour contrast checks for colour pairs or CSS. Use when auditing templates for accessibility, checking contrast, or adding an a11y gate to CI.
/agent-designerDesigns multi-agent system architectures with orchestration patterns, tool schemas, and performance evaluation. Use when building AI agent systems, designing agent workflows, creating tool schemas, or evaluating agent performance.
/agent-harnessTest and evaluation harness for AI agents — scenario suites, deterministic replay, regression diffing, cost and latency budgets. Use when agent quality is vibe-checked, before shipping a prompt or model change, or when evals drift.
/agenthubRuns a multi-agent job as a dependency graph: validates the DAG, tracks each agent's state on a board, then ranks and merges their outputs. Use when spawning parallel agents, monitoring a run, or merging results.
/agentic-evaluation-frameworkBuilds LLM and agent evals: weighted rubrics, LLM-as-judge design, inter-rater agreement and pairwise ranking (Elo, Bradley-Terry) from scores you collect. Use when setting up a judge, scoring outputs, or comparing model or prompt variants.
/agent-protocolDesign AI agent communication protocols: MCP tool schemas, A2A, function calling, and inter- agent messaging. Use when building multi-agent systems, defining tool interfaces, or implementing agent-to-agent communication.
npx claudepluginhub borghei/claude-skills --plugin engineering-advanced-skillsOther plugins' skills for the same job