docker-compose-generator
Skill1 starsChanged 5 months agoApache-2.0View on GitHub
Generates production-ready docker-compose.yml files for multi-service applications. Use when containerizing an app with databases, caches, or other services.
- Reads credentials
1 other project uses a version of this.
Adopted by
Most recently taken up by
- timwukp/agent-skills-best-practicetheir own version, first seen Sep 16, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- timwukp/agent-skills-best-practice★ 10same 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 repository58 other files it gives its agents.
- agent-chain-designerSkill
- api-wrapper-builderSkill
- embeddings-builderSkill
- evaluation-harnessSkill
- fine-tuning-preparerSkill
- llm-router-builderSkill
- ml-model-trainerSkill
- model-benchmarkerSkill
- prompt-engineerSkill
- rag-pipeline-builderSkill
- synthetic-data-generatorSkill
- vector-db-integratorSkill
- csv-processorSkill
- database-schema-designerSkill
- data-pipeline-builderSkill
- etl-workflow-designerSkill
- json-transformerSkill
- pandas-data-cleanerSkill
- report-generatorSkill
- sql-query-optimizerSkill
- time-series-analyzerSkill
- visualization-generatorSkill
- backup-strategySkill
- ci-cd-optimizerSkill
- github-actions-pipelineSkill
- kubernetes-deploymentSkill
- load-balancer-configSkill
- log-aggregator-setupSkill
- monitoring-dashboardSkill
- nginx-config-generatorSkill
- security-hardeningSkill
- ssl-certificate-managerSkill
- terraform-module-builderSkill
- api-security-auditorSkill
- compliance-checkerSkill
- dependency-checkerSkill
- incident-responderSkill
- jwt-security-auditorSkill
- owasp-checkerSkill
- penetration-test-plannerSkill
- secret-detectorSkill
- threat-model-designerSkill
- vulnerability-scannerSkill
- accessibility-auditorSkill
- api-route-builderSkill
- auth-flow-builderSkill
- css-animation-crafterSkill
- form-validatorSkill
- graphql-schema-designerSkill
- html-component-builderSkill
- nextjs-app-scaffoldSkill
- performance-auditorSkill
- pwa-setupSkill
- react-component-generatorSkill
- responsive-layout-systemSkill
- seo-optimizerSkill
- tailwind-design-systemSkill
- websocket-integrationSkill
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 50
Use Docker secrets or external secret managers for prod.
- Distinctive: line 52
Never put real credentials in the committed compose file.
- Very specific: line 75
Database initialization: Use depends_on + healthcheck, and an init container or entrypoint script that waits for DB.
- Distinctive: line 76
Permission issues with volumes: Run containers as non-root user.
- Very specific: line 77
Secrets in CI: Use GitHub Secrets or similar + docker compose with --env-file from secrets.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Overview
Generates secure, production-oriented docker-compose.yml (and docker-compose.override.yml for local dev) with proper service definitions, networks, volumes, healthchecks, resource limits, environment variable management, secrets handling, and restart policies. Includes full examples for common stacks (Node.js + Postgres + Redis, Python + Postgres + Redis, etc.).
When to Use This Skill
- Containerizing a new or existing multi-service application.
- The user says "docker-compose", "containerize", "local dev environment with DB", or "production docker setup".
- Setting up consistent environments across developer machines and CI/CD.
Prerequisites
- Docker Desktop or Docker Engine + Compose V2 installed.
- Application code that can be containerized (Dockerfile exists or can be created).
- Understanding of the services needed (database, cache, queue, etc.).
Steps
- Inventory all services the app needs (app, db, cache, queue, search, etc.).
- Define networks:
frontend(for reverse proxy / app).backend(internal, for app ↔ db, app ↔ cache).
- Define volumes for persistent data (named volumes preferred over bind mounts in production).
- Service definition template (for each service):
imageorbuild.environmentorenv_file(never commit secrets in prod compose).volumes.networks.healthcheck(critical).restart: unless-stopped.deploy.resourceslimits/requests (for Swarm or when using compose with limits).depends_onwith condition: service_healthy.
- Secrets & config:
- Use Docker secrets or external secret managers for prod.
- For local:
.envloaded viaenv_file. - Never put real credentials in the committed compose file.
- Healthchecks:
- DB:
pg_isready,mysqladmin ping, etc. - App:
/healthendpoint that checks DB connectivity.
- DB:
- Local vs prod:
docker-compose.ymlfor prod-like.docker-compose.override.yml(auto-loaded) for local dev (hot reload, different ports, debug flags).
- Output:
- Full
docker-compose.yml. - Example
Dockerfilefor the app if missing. .env.example.- Commands to bring up, view logs, run migrations, etc.
- Production notes (use
docker compose up -d, logging drivers, etc.).
- Full
Examples
Complete docker-compose.yml for a Node.js + PostgreSQL + Redis + optional Nginx reverse proxy stack, with healthchecks, named volumes, proper networking, and a matching override for local development is included, along with the corresponding Dockerfiles and .env.example.
Edge Cases & Error Handling
- Database initialization: Use
depends_on+ healthcheck, and an init container or entrypoint script that waits for DB. - Permission issues with volumes: Run containers as non-root user; set correct UID/GID on volumes.
- Secrets in CI: Use GitHub Secrets or similar +
docker composewith--env-filefrom secrets. - Scaling: Note that some services (Postgres) are not easily horizontally scaled in compose; recommend managed DB for prod.
Verification
docker compose config— validates syntax.docker compose up --build -d— all services healthy (checkdocker compose ps).- App can connect to DB and Redis (test endpoints).
docker compose down -vcleans up.- Success: Environment is reproducible, services start reliably, data persists across restarts, and no secrets are in the repo.
References
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.

