docker

docker is a skill for Claude Code, Codex from ashish7802/awesome-api-skills. It costs 0 tokens per session (527 once invoked), scanned A, original, MIT.

A guide to Docker, a tool that packages an application and its required files into isolated containers. It covers basic commands, production image structure, caching, and process handling.

In plain words
What is it for?
Use it when building Docker images, running applications in containers, preparing production images, or improving Docker build and runtime practices.
Why use it?
It helps avoid differences between development and production environments and explains how to keep container builds smaller and faster.

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/ashish7802/awesome-api-skills/docker
Any agent
npx skills add ashish7802/awesome-api-skills --skill docker
Clone the repo
git clone --depth 1 https://github.com/ashish7802/awesome-api-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for docker

README.md
[![agentmods](https://agentmods.dev/badge/skills/ashish7802/awesome-api-skills/docker.svg)](https://agentmods.dev/skills/ashish7802/awesome-api-skills/docker)
Your own site
<a href="https://agentmods.dev/skills/ashish7802/awesome-api-skills/docker"><img src="https://agentmods.dev/badge/skills/ashish7802/awesome-api-skills/docker.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 527 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00000 $0.00527
Opus 5 $0.00000 $0.00264
Sonnet 5 $0.00000 $0.00105
Haiku 4.5 $0.00000 $0.00053

Measured 5d ago against content hash ccac9fd3fae7, 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 0 findings 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 5d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/docker/SKILL.md · 63 lines

How it starts

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

Docker Skill

OS-level virtualization to deliver software in packages called containers.

Ecosystem Graph

graph LR
  docker["Docker"]
  docker -- "deploys to" --> kubernetes
  docker -- "integrates with" --> github-actions

Quick Start

Docker packages your application and its dependencies into an immutable image, ensuring 'it works on my machine' scales to production.

docker build -t my-app .
docker run -p 8080:8080 my-app

Production Patterns

Multi-Stage Builds

Never ship build tools (like compilers or dev dependencies) in your final production image. Use a build stage to compile your code, then copy only the compiled artifacts into a distroless or alpine base image for the final stage.

Architecture & Scaling

Image Caching

Docker builds images in layers. Order your Dockerfile from least frequently changed (OS dependencies, package managers) to most frequently changed (source code). This ensures Docker caches the heavy steps and dramatically speeds up CI pipelines.

Error Recovery

Use a process manager like PM2 or tini as PID 1 inside your container to properly handle OS signals (SIGTERM/SIGINT) and reap zombie processes, allowing graceful shutdowns.

Security Notes

Never run your container as the root user. Explicitly create and switch to a non-root USER at the end of your Dockerfile. Scan your images using tools like Trivy or Docker Scout to catch CVEs before deployment.

Relationships

Works Well With: github-actions

Deploys To: kubernetes

References

Why use this skill

Use this when your agent works with docker — structured patterns beat pasted docs and prevent common hallucinations.

AI pitfalls

  • Referencing CLI flags or config keys that do not exist
  • Using outdated major versions of tools
  • Skipping lockfile or version pinning in examples

Production checklist

  • Secrets in environment variables, not source code
  • Error handling and logging in place
  • Rate limits and timeouts configured

Read the full file on GitHub · 63 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 5d ago First seen · 63 lines · 0 tokens per session scan A ccac9fd3fae7

Subscribe to this mod's changes

docker is a skill published in the GitHub repository ashish7802/awesome-api-skills (13 stars, last pushed 4d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 527 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

deploy-docker-compose

Run the Omnigent server as a Docker compose stack (server + Postgres) on any Docker host — your laptop, a VPS, EC2 by hand, or as the base layer of any container-platform deploy. Invoke when the user wants to build the image, bring up the compose stack, debug the stack on a host they already have, or extend the stack…

omnigent-ai/omnigent · 84 tokens

azure-prepare

Prepare azd-based Azure projects for deployment: generates azure.yaml, infrastructure (Bicep/Terraform), and Dockerfiles for the Azure Developer CLI (azd) workflow. USE ONLY when the user explicitly wants to use azd as the deployment tool, or the project already has an azure.yaml file. DO NOT USE FOR: non-azd…

microsoft/skills · 166 tokens

azure-cloud-migrate

Assess and migrate cross-cloud workloads to Azure with reports and code conversion. Supports Lambda→Functions, Beanstalk/Heroku/App Engine→App Service, Fargate/Kubernetes/Cloud Run/Spring Boot→Container Apps. WHEN: migrate Lambda to Functions, AWS to Azure, migrate Beanstalk, migrate Heroku, migrate App Engine, Cloud…

microsoft/skills · 106 tokens

docker-patterns

Docker and Docker Compose patterns for local development, container security, networking, volume strategies, and multi-service orchestration.

hashgraph-online/awesome-codex-plugins · 27 tokens

cloudron-app-packaging

Official Cloudron app packaging skill - Dockerfile patterns, manifest, addons, build methods.

marcusquinn/aidevops · 23 tokens

devops-deployment

Use when setting up CI/CD pipelines, containerizing applications, deploying to Kubernetes, or writing infrastructure as code. DevOps & Deployment covers GitHub Actions, Docker, Helm, and Terraform patterns.

yonatangross/orchestkit · 44 tokens