
Docker patterns
Docker and Compose patterns for dev stacks, container hardening and isolated installer
Docker patterns is an open-source agent skill for developer tools. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.
- Scripts
- None
- Platforms
- Claude Code, Codex, Cursor
- GitHub stars
- 66
- Last commit
- License
- MIT
- Listing updated
Similar skills
About Docker patterns
This skill gives an agent a reference set of Docker and Docker Compose patterns for local development: multi-service stacks with Postgres, Redis and a mail catcher, multi-stage Dockerfiles that separate dev and production targets, override files, service networking, and volume layouts. It also covers container security, including pinned tags, non-root users, read-only root filesystems, dropped capabilities and keeping secrets out of images.
A larger part of the guide describes a hardened harness for testing command-line installers inside disposable containers. The agent is pointed at a Compose file for running installer checks against Debian and Ubuntu images on a read-only source mount, with a dry-run default, no network unless explicitly enabled, and no host credentials mounted. It also explains where Linux containers stop being useful, since macOS and Windows behavior must be checked natively on those hosts.
The guidance assumes Docker with the Compose plugin and a Linux host for the container steps. The installer examples reference a specific project's Compose file and npm scripts, so they apply to that repository rather than to arbitrary projects.
When your agent uses it
Docker and Docker Compose patterns for local development, hardened CLI installer harnesses, container security, networking, volumes, and multi-service orchestration. Use when creating or reviewing Dockerfiles and Compose services, testing installers across Linux distributions, or planning accurate native macOS and Windows validation.
From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.
What it can access
From a static check of its 2 files (17 KB) on GitHub on 1 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.
Check another skill before you install it.
Install
This skill ships in the rea-skills plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):
/plugin marketplace add smartworldarafath/REA_Skill
/plugin install rea-skills@smartworldarafathOr copy only this skill to ~/.claude/skills/docker-patterns:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/docker-patterns &&
cp -R "$tmp/.agents/skills/docker-patterns" ~/.claude/skills/docker-patterns &&
rm -rf "$tmp"For one project only, put the folder in .claude/skills/docker-patterns inside it instead.
Copy the skill folder to ~/.agents/skills/docker-patterns to use it in every repository:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/docker-patterns &&
cp -R "$tmp/.agents/skills/docker-patterns" ~/.agents/skills/docker-patterns &&
rm -rf "$tmp"For one repository only, put the folder in .agents/skills/docker-patterns inside it instead.
Copy the skill folder to ~/.cursor/skills/docker-patterns to use it in every project:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/docker-patterns &&
cp -R "$tmp/.agents/skills/docker-patterns" ~/.cursor/skills/docker-patterns &&
rm -rf "$tmp"For one project only, put the folder in .cursor/skills/docker-patterns inside it instead.
Run in a terminal (add --scope workspace to install it for the current workspace only):
gemini skills install https://github.com/smartworldarafath/REA_Skill.git --path .agents/skills/docker-patternsOr copy the folder to ~/.gemini/skills/docker-patterns yourself.
For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/docker-patterns:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/docker-patterns &&
cp -R "$tmp/.agents/skills/docker-patterns" ~/.copilot/skills/docker-patterns &&
rm -rf "$tmp"For one project only, put the folder in .github/skills/docker-patterns inside it instead.
Get the folder:
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.gitThen copy REA_Skill/.agents/skills/docker-patterns into your agent's skills folder as docker-patterns. Agents that support SKILL.md read one folder per skill.
What it does
- Compose stack setup
- Templates for wiring an app with a database, cache and mail service into one Compose file with health checks.
- Multi-stage Dockerfiles
- Patterns that split dependency, development, build and production stages into separate Dockerfile targets.
- Container hardening
- Guidance on pinned tags, non-root users, read-only filesystems, dropped capabilities and secret handling.
- Network and volume layout
- Examples of custom networks that isolate services and volume choices for persistent data and hot reload.
- Isolated installer testing
- A harness pattern that runs installer checks in Linux containers against copies of a project with no network by default.
- Debugging commands
- A quick reference of Compose commands for logs, shells, process inspection, resource use and DNS checks.
Good for
- Set up a local Compose stack with Postgres and Redis for a web app
- Review a Dockerfile for non-root users, pinned tags and secret leakage
- Split a Dockerfile into dev and production stages
- Test a CLI installer across Debian and Ubuntu containers without touching the source checkout
- Work out which installer checks must run natively on macOS or Windows
Docker patterns FAQ
Does Docker patterns need any scripts or tools installed?
It contains no scripts of its own. It assumes Docker with Compose is available, and the installer harness section relies on a project-specific Compose file and npm scripts.
Can a Linux container validate macOS or Windows behavior?
No. The guide says Linux containers cannot validate macOS or Windows behavior, so those checks should run on native CI runners for each platform.
When does the agent use Docker patterns?
According to its description, it applies when creating or reviewing Dockerfiles and Compose services, testing installers across Linux distributions, or planning native macOS and Windows validation.
How do I install Docker patterns in Claude Code?
Copy the skill folder from GitHub to ~/.claude/skills/docker-patterns to use it in all your projects, or to .claude/skills/docker-patterns in one project. Or install the rea-skills plugin, which includes it: /plugin marketplace add smartworldarafath/REA_Skill, then /plugin install rea-skills@smartworldarafath.
Does Docker patterns run scripts?
No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.
Which AI agents can use Docker patterns?
Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.
What are the best alternatives to Docker patterns?
The closest alternatives to Docker patterns are Deployment patterns, Gem devops guidelines, Containerize aspnetcore, Java testcontainers and Containerize aspnet framework.
Where this comes from
- Description: from the skill's own SKILL.md.
More from smartworldarafath/REA_Skill

Guides building and auditing UI to WCAG 2.2 AA across web, iOS and Android
- Open source
- 66 GitHub stars
- Developer tools

Diagnoses agent and LLM stacks for hidden failures and ranks the fixes by severity
- Open source
- 66 GitHub stars
- Developer tools

Compare coding agents head-to-head on your own tasks by pass rate, cost and time
- Open source
- 66 GitHub stars
- Developer tools

Guides an agent to design tool sets, observations and error recovery for better completion
- Open source
- 66 GitHub stars
- Developer tools

Gives an agent a structured capture-diagnose-recover loop for failing runs
- Open source
- 66 GitHub stars
- Developer tools

Lets an AI agent make x402 payments within per-task budgets and spending policies
- Open source
- 66 GitHub stars
- Finance and payments


