dockerize
Skill0 starsChanged 6 days agoMITView on GitHub
Containerize an existing project with a production-ready Dockerfile, .dockerignore and docker-compose.yml, then build and run it to verify. Use when the user says "dockerize this", "add a Dockerfile", "run this in Docker", "containerize the app", or "docker-compose for local dev".
- Reads credentials
- Installs packages
5 other projects use a version of this.
Adopted by
Most recently taken up by
- kratocz/skillstheir own version, first seen Nov 15, 2026
- OneByJorah/VirtOfficetheir own version, first seen Nov 1, 2026
- OneByJorah/offivotheir own version, first seen Oct 20, 2026
- Pradnyeshp/Claude-Skillstheir own version, first seen Jul 6, 2026
- walterlow/claude-skillstheir own version, first seen Jan 30, 2026
Other versions5 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 5
- OneByJorah/offivo★ 24same name
- OneByJorah/VirtOffice★ 24same name
- Pradnyeshp/Claude-Skills★ 2same name
- walterlow/claude-skills★ 2same name
- kratocz/skills★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository24 other files it gives its agents.
- api-docsSkill
- changelogSkill
- ci-failure-fixSkill
- code-reviewSkill
- commit-messageSkill
- competitor-analysisSkill
- data-analystSkill
- debug-detectiveSkill
- dependency-upgradeSkill
- email-replierSkill
- eval-promptSkill
- incident-postmortemSkill
- meeting-notesSkill
- migration-safetySkill
- pr-descriptionSkill
- product-specSkill
- readme-writerSkill
- refactor-safelySkill
- research-briefSkill
- security-checkSkill
- seo-articleSkill
- sql-helperSkill
- support-replySkill
- write-testsSkill
The file
We split this skill into the rules it gives an agent
4 rules. 0 are common, 1 is distinctive, and 3 are very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
If a Dockerfile already exists, improve it instead of replacing it.
- Very specific: line 24
Run as a non-root user (the node user in node images, or create one).
- Very specific: line 28
No secrets in ARG, ENV or copied files.
- Very specific: line 54
If the user builds on Apple Silicon and deploys to x86 servers, mention docker build --platform linux/amd64.
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Dockerize an app
1. Detect the stack
- Language and runtime version:
.nvmrc,engines,.python-version,pyproject.toml,go.mod,Gemfile,.tool-versions. Use the same major version in the base image. - Package manager from the lockfile (npm, pnpm, yarn, poetry, uv, pip). No lockfile: tell the user builds will not be reproducible.
- Build and start commands from
package.jsonscripts,Procfile,Makefile, or the framework. - Port, and the env vars the app needs (
.env.example, config reads in code). - Services it talks to: database, cache, queue, object storage.
- If a Dockerfile already exists, improve it instead of replacing it.
2. Dockerfile
- Official base image with a pinned version tag (
node:22-bookworm-slim,python:3.12-slim). Avoidlatest. Prefer Debian slim over Alpine unless the user wants Alpine: musl breaks some native packages and prebuilt binaries (Prisma, sharp, many Python wheels). - Multi-stage: dependencies and build in one stage, copy only runtime artifacts into the final stage.
- Copy lockfile and manifest first, install, then copy source, so the install layer caches.
- Reproducible installs:
npm ci,pnpm install --frozen-lockfile,yarn install --immutable,pip install --no-cache-dir -r requirements.txt,uv sync --frozen. Production-only dependencies in the final stage. - Framework specifics: Next.js with
output: "standalone"; Python withPYTHONUNBUFFERED=1; compiled Go/Rust into a minimal or distroless image. - Run as a non-root user (the
nodeuser in node images, or create one). - Exec-form
CMD ["node", "server.js"]so the process gets SIGTERM and shuts down cleanly. Avoidnpm startas PID 1; it may not forward signals. - The app must listen on
0.0.0.0, notlocalhost/127.0.0.1, or it will be unreachable from outside the container. Check the code and setHOSTif needed. HEALTHCHECKonly if there is a health endpoint and a tool to call it exists in the image (slim images have nocurl; use the runtime itself, e.g.node -e "fetch(...)").- No secrets in
ARG,ENVor copied files; they stay in image layers. Pass them at runtime.
3. .dockerignore
.git, node_modules, virtualenvs, build output, .env* (keep .env.example only if needed), logs, coverage, local DB files, OS files. Without it, the build context leaks secrets and busts the cache.
4. docker-compose.yml
- The app plus the real dependencies it needs locally, using official images with pinned versions.
- Named volumes for data,
env_file: .envfor config, ports mapped explicitly. depends_onwithcondition: service_healthyand a healthcheck on the database, so the app does not start before it is ready.- Inside compose, the app reaches the DB at the service name (
db:5432), notlocalhost. Point the connection string there. - Database migrations: a separate one-off command or service, not baked into the image build.
5. Build, run, verify
docker build -t <app> .
docker compose up -d
docker compose ps
docker compose logs app --tail 50
curl -i http://localhost:<port>/<health-or-root>
docker image ls <app>Fix and rebuild until the container starts, stays up and responds. Report the final image size.
If the user builds on Apple Silicon and deploys to x86 servers, mention docker build --platform linux/amd64.
Report
Files created, commands to build and run, env vars the user must set, and anything you could not verify (for example, services you could not start locally).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

