Agent skill
docker-compose-basics
Use when defining and running multi-container Docker applications with Docker Compose YAML configuration.
Install this agent skill to your Project
npx add-skill https://github.com/TheBushidoCollective/han/tree/main/plugins/tools/docker-compose/skills/docker-compose-basics
SKILL.md
Docker Compose Basics
Docker Compose for defining and running multi-container applications.
Basic Structure
version: '3.8'
services:
web:
image: nginx:latest
ports:
- "80:80"
volumes:
- ./html:/usr/share/nginx/html
environment:
- NGINX_HOST=localhost
depends_on:
- api
api:
build: ./api
ports:
- "3000:3000"
environment:
DATABASE_URL: postgres://db:5432/myapp
depends_on:
- db
db:
image: postgres:15
volumes:
- pgdata:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: secret
POSTGRES_DB: myapp
volumes:
pgdata:
Common Commands
# Start services
docker compose up
# Start in background
docker compose up -d
# Stop services
docker compose down
# View logs
docker compose logs -f
# Rebuild
docker compose build
# Execute command
docker compose exec web sh
# Scale service
docker compose up -d --scale api=3
Best Practices
Environment Variables
services:
api:
environment:
- NODE_ENV=${NODE_ENV:-development}
- API_KEY=${API_KEY}
Health Checks
services:
web:
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost"]
interval: 30s
timeout: 10s
retries: 3
Resource Limits
services:
api:
deploy:
resources:
limits:
cpus: '0.5'
memory: 512M
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
create-blog-post
Research Reddit discussions and write a blog post about how Han addresses the topic
research-new-features
Research Claude AI/Code feature requests and discussions on Reddit
create-jutsu
Create a new technique plugin for a technology (language, tool, framework, or validation)
create-do
Create a new discipline plugin with specialized agents
create-hashi
Create a new bridge plugin for MCP server integration
plugin-development
Use when creating or modifying Han plugins. Covers plugin structure, configuration, hooks, skills, and best practices.
Didn't find tool you were looking for?