[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75QAPVQEDBH8A2BYR3GC83R":3,"skill-same:01M75QAPVQEDBH8A2BYR3GC83R":68},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":28,"commitSha":29,"skillDirectory":30,"forksCount":13,"repositoryHtmlUrl":31,"repositoryHomepageUrl":6,"ownerHtmlUrl":32,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":33,"install":34,"resources":47},"01M75QAPVQEDBH8A2BYR3GC83R","docker-development",null,"Docker and container development agent skill and plugin for Dockerfile optimization, docker-compose orchestration, multi-stage builds, and container security hardening. Use when: user wants to optimize a Dockerfile, create or improve docker-compose configurations, implement multi-stage builds, audit container security, reduce image size, or follow container best practices. Covers build performance, layer caching, secret management, and production-ready container patterns.","TehutiRaEl\u002FTHEHIVE","TehutiRaEl","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F267495122?v=4","01M75N1QQQHT359S3XMYK7NPCB","01M75N1QRAW5P8P43HEHWMXCTE",0,"MIT","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fengineering\u002Fdocker-development\u002Fskills\u002Fdocker-development\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: \"docker-development\"\ndescription: \"Docker and container development agent skill and plugin for Dockerfile optimization, docker-compose orchestration, multi-stage builds, and container security hardening. Use when: user wants to optimize a Dockerfile, create or improve docker-compose configurations, implement multi-stage builds, audit container security, reduce image size, or follow container best practices. Covers build performance, layer caching, secret management, and production-ready container patterns.\"\nlicense: MIT\nmetadata:\n  version: 1.0.0\n  author: Alireza Rezvani\n  category: engineering\n  updated: 2026-03-16\n---\n\n# Docker Development\n\n> Smaller images. Faster builds. Secure containers. No guesswork.\n\nOpinionated Docker workflow that turns bloated Dockerfiles into production-grade containers. Covers optimization, multi-stage builds, compose orchestration, and security hardening.\n\nNot a Docker tutorial — a set of concrete decisions about how to build containers that don't waste time, space, or attack surface.\n\n---\n\n## Slash Commands\n\n| Command | What it does |\n|---------|-------------|\n| `\u002Fdocker:optimize` | Analyze and optimize a Dockerfile for size, speed, and layer caching |\n| `\u002Fdocker:compose` | Generate or improve docker-compose.yml with best practices |\n| `\u002Fdocker:security` | Audit a Dockerfile or running container for security issues |\n\n---\n\n## When This Skill Activates\n\nRecognize these patterns from the user:\n\n- \"Optimize this Dockerfile\"\n- \"My Docker build is slow\"\n- \"Create a docker-compose for this project\"\n- \"Is this Dockerfile secure?\"\n- \"Reduce my Docker image size\"\n- \"Set up multi-stage builds\"\n- \"Docker best practices for [language\u002Fframework]\"\n- Any request involving: Dockerfile, docker-compose, container, image size, build cache, Docker security\n\nIf the user has a Dockerfile or wants to containerize something → this skill applies.\n\n---\n\n## Workflow\n\n### `\u002Fdocker:optimize` — Dockerfile Optimization\n\n1. **Analyze current state**\n   - Read the Dockerfile\n   - Identify base image and its size\n   - Count layers (each RUN\u002FCOPY\u002FADD = 1 layer)\n   - Check for common anti-patterns\n\n2. **Apply optimization checklist**\n\n   ```\n   BASE IMAGE\n   ├── Use specific tags, never :latest in production\n   ├── Prefer slim\u002Falpine variants (debian-slim > ubuntu > debian)\n   ├── Pin digest for reproducibility in CI: image@sha256:...\n   └── Match base to runtime needs (don't use python:3.12 for a compiled binary)\n\n   LAYER OPTIMIZATION\n   ├── Combine related RUN commands with && \\\n   ├── Order layers: least-changing first (deps before source code)\n   ├── Clean package manager cache in the same RUN layer\n   ├── Use .dockerignore to exclude unnecessary files\n   └── Separate build deps from runtime deps\n\n   BUILD CACHE\n   ├── COPY dependency files before source code (package.json, requirements.txt, go.mod)\n   ├── Install deps in a separate layer from code copy\n   ├── Use BuildKit cache mounts: --mount=type=cache,target=\u002Froot\u002F.cache\n   └── Avoid COPY . . before dependency installation\n\n   MULTI-STAGE BUILDS\n   ├── Stage 1: build (full SDK, build tools, dev deps)\n   ├── Stage 2: runtime (minimal base, only production artifacts)\n   ├── COPY --from=builder only what's needed\n   └── Final image should have NO build tools, NO source code, NO dev deps\n   ```\n\n3. **Generate optimized Dockerfile**\n   - Apply all relevant optimizations\n   - Add inline comments explaining each decision\n   - Report estimated size reduction\n\n4. **Validate**\n   ```bash\n   python3 scripts\u002Fdockerfile_analyzer.py Dockerfile\n   ```\n\n### `\u002Fdocker:compose` — Docker Compose Configuration\n\n1. **Identify services**\n   - Application (web, API, worker)\n   - Database (postgres, mysql, redis, mongo)\n   - Cache (redis, memcached)\n   - Queue (rabbitmq, kafka)\n   - Reverse proxy (nginx, traefik, caddy)\n\n2. **Apply compose best practices**\n\n   ```\n   SERVICES\n   ├── Use depends_on with condition: service_healthy\n   ├── Add healthchecks for every service\n   ├── Set resource limits (mem_limit, cpus)\n   ├── Use named volumes for persistent data\n   └── Pin image versions\n\n   NETWORKING\n   ├── Create explicit networks (don't rely on default)\n   ├── Separate frontend and backend networks\n   ├── Only expose ports that need external access\n   └── Use internal: true for backend-only networks\n\n   ENVIRONMENT\n   ├── Use env_file for secrets, not inline environment\n   ├── Never commit .env files (add to .gitignore)\n   ├── Use variable substitution: ${VAR:-default}\n   └── Document all required env vars\n\n   DEVELOPMENT vs PRODUCTION\n   ├── Use compose profiles or override files\n   ├── Dev: bind mounts for hot reload, debug ports exposed\n   ├── Prod: named volumes, no debug ports, restart: unless-stopped\n   └── docker-compose.override.yml for dev-only config\n   ```\n\n3. **Generate compose file**\n   - Output docker-compose.yml with healthchecks, networks, volumes\n   - Generate .env.example with all required variables documented\n   - Add dev\u002Fprod profile annotations\n\n### `\u002Fdocker:security` — Container Security Audit\n\n1. **Dockerfile audit**\n\n   | Check | Severity | Fix |\n   |-------|----------|-----|\n   | Running as root | Critical | Add `USER nonroot` after creating user |\n   | Using :latest tag | High | Pin to specific version |\n   | Secrets in ENV\u002FARG | Critical | Use BuildKit secrets: `--mount=type=secret` |\n   | COPY with broad glob | Medium | Use specific paths, add .dockerignore |\n   | Unnecessary EXPOSE | Low | Only expose ports the app uses |\n   | No HEALTHCHECK | Medium | Add HEALTHCHECK with appropriate interval |\n   | Privileged instructions | High | Avoid `--privileged`, drop capabilities |\n   | Package manager cache retained | Low | Clean in same RUN layer |\n\n2. **Runtime security checks**\n\n   | Check | Severity | Fix |\n   |-------|----------|-----|\n   | Container running as root | Critical | Set user in Dockerfile or compose |\n   | Writable root filesystem | Medium | Use `read_only: true` in compose |\n   | All capabilities retained | High | Drop all, add only needed: `cap_drop: [ALL]` |\n   | No resource limits | Medium | Set `mem_limit` and `cpus` |\n   | Host network mode | High | Use bridge or custom network |\n   | Sensitive mounts | Critical | Never mount \u002Fetc, \u002Fvar\u002Frun\u002Fdocker.sock in prod |\n   | No log driver configured | Low | Set `logging:` with size limits |\n\n3. **Generate security report**\n   ```\n   SECURITY AUDIT — [Dockerfile\u002FImage name]\n   Date: [timestamp]\n\n   CRITICAL: [count]\n   HIGH:     [count]\n   MEDIUM:   [count]\n   LOW:      [count]\n\n   [Detailed findings with fix recommendations]\n   ```\n\n---\n\n## Tooling\n\n### `scripts\u002Fdockerfile_analyzer.py`\n\nCLI utility for static analysis of Dockerfiles.\n\n**Features:**\n- Layer count and optimization suggestions\n- Base image analysis with size estimates\n- Anti-pattern detection (15+ rules)\n- Security issue flagging\n- Multi-stage build detection and validation\n- JSON and text output\n\n**Usage:**\n```bash\n# Analyze a Dockerfile\npython3 scripts\u002Fdockerfile_analyzer.py Dockerfile\n\n# JSON output\npython3 scripts\u002Fdockerfile_analyzer.py Dockerfile --output json\n\n# Analyze with security focus\npython3 scripts\u002Fdockerfile_analyzer.py Dockerfile --security\n\n# Check a specific directory\npython3 scripts\u002Fdockerfile_analyzer.py path\u002Fto\u002FDockerfile\n```\n\n### `scripts\u002Fcompose_validator.py`\n\nCLI utility for validating docker-compose files.\n\n**Features:**\n- Service dependency validation\n- Healthcheck presence detection\n- Network configuration analysis\n- Volume mount validation\n- Environment variable audit\n- Port conflict detection\n- Best practice scoring\n\n**Usage:**\n```bash\n# Validate a compose file\npython3 scripts\u002Fcompose_validator.py docker-compose.yml\n\n# JSON output\npython3 scripts\u002Fcompose_validator.py docker-compose.yml --output json\n\n# Strict mode (fail on warnings)\npython3 scripts\u002Fcompose_validator.py docker-compose.yml --strict\n```\n\n---\n\n## Multi-Stage Build Patterns\n\n### Pattern 1: Compiled Language (Go, Rust, C++)\n\n```dockerfile\n# Build stage\nFROM golang:1.22-alpine AS builder\nWORKDIR \u002Fapp\nCOPY go.mod go.sum .\u002F\nRUN go mod download\nCOPY . .\nRUN CGO_ENABLED=0 go build -ldflags=\"-s -w\" -o \u002Fapp\u002Fserver .\u002Fcmd\u002Fserver\n\n# Runtime stage\nFROM gcr.io\u002Fdistroless\u002Fstatic-debian12\nCOPY --from=builder \u002Fapp\u002Fserver \u002Fserver\nUSER nonroot:nonroot\nENTRYPOINT [\"\u002Fserver\"]\n```\n\n### Pattern 2: Node.js \u002F TypeScript\n\n```dockerfile\n# Dependencies stage\nFROM node:20-alpine AS deps\nWORKDIR \u002Fapp\nCOPY package.json package-lock.json .\u002F\nRUN npm ci --production=false\n\n# Build stage\nFROM deps AS builder\nCOPY . .\nRUN npm run build\n\n# Runtime stage\nFROM node:20-alpine\nWORKDIR \u002Fapp\nRUN addgroup -g 1001 -S appgroup && adduser -S appuser -u 1001\nCOPY --from=builder \u002Fapp\u002Fdist .\u002Fdist\nCOPY --from=deps \u002Fapp\u002Fnode_modules .\u002Fnode_modules\nCOPY package.json .\u002F\nUSER appuser\nEXPOSE 3000\nCMD [\"node\", \"dist\u002Findex.js\"]\n```\n\n### Pattern 3: Python\n\n```dockerfile\n# Build stage\nFROM python:3.12-slim AS builder\nWORKDIR \u002Fapp\nCOPY requirements.txt .\nRUN pip install --no-cache-dir --prefix=\u002Finstall -r requirements.txt\n\n# Runtime stage\nFROM python:3.12-slim\nWORKDIR \u002Fapp\nRUN groupadd -r appgroup && useradd -r -g appgroup appuser\nCOPY --from=builder \u002Finstall \u002Fusr\u002Flocal\nCOPY . .\nUSER appuser\nEXPOSE 8000\nCMD [\"python\", \"-m\", \"uvicorn\", \"main:app\", \"--host\", \"0.0.0.0\", \"--port\", \"8000\"]\n```\n\n---\n\n## Base Image Decision Tree\n\n```\nIs it a compiled binary (Go, Rust, C)?\n├── Yes → distroless\u002Fstatic or scratch\n└── No\n    ├── Need a shell for debugging?\n    │   ├── Yes → alpine variant (e.g., node:20-alpine)\n    │   └── No → distroless variant\n    ├── Need glibc (not musl)?\n    │   ├── Yes → slim variant (e.g., python:3.12-slim)\n    │   └── No → alpine variant\n    └── Need specific OS packages?\n        ├── Many → debian-slim\n        └── Few → alpine + apk add\n```\n\n---\n\n## Proactive Triggers\n\nFlag these without being asked:\n\n- **Dockerfile uses :latest** → Suggest pinning to a specific version tag.\n- **No .dockerignore** → Create one. At minimum: `.git`, `node_modules`, `__pycache__`, `.env`.\n- **COPY . . before dependency install** → Cache bust. Reorder to install deps first.\n- **Running as root** → Add USER instruction. No exceptions for production.\n- **Secrets in ENV or ARG** → Use BuildKit secret mounts. Never bake secrets into layers.\n- **Image over 1GB** → Multi-stage build required. No reason for a production image this large.\n- **No healthcheck** → Add one. Orchestrators (Compose, K8s) need it for proper lifecycle management.\n- **apt-get without cleanup in same layer** → `rm -rf \u002Fvar\u002Flib\u002Fapt\u002Flists\u002F*` in the same RUN.\n\n---\n\n## Installation\n\n### One-liner (any tool)\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Falirezarezvani\u002Fclaude-skills.git\ncp -r claude-skills\u002Fengineering\u002Fdocker-development ~\u002F.claude\u002Fskills\u002F\n```\n\n### Multi-tool install\n```bash\n.\u002Fscripts\u002Fconvert.sh --skill docker-development --tool codex|gemini|cursor|windsurf|openclaw\n```\n\n### OpenClaw\n```bash\nclawhub install cs-docker-development\n```\n\n---\n\n## Related Skills\n\n- **senior-devops** — Broader DevOps scope (CI\u002FCD, IaC, monitoring). Complementary — use docker-development for container-specific work, senior-devops for pipeline and infrastructure.\n- **senior-security** — Application security. Complementary — docker-development covers container security, senior-security covers application-level threats.\n- **autoresearch-agent** — Can optimize Docker build times or image sizes as measurable experiments.\n- **ci-cd-pipeline-builder** — Pipeline construction. Complementary — docker-development builds the containers, ci-cd-pipeline-builder deploys them.\n","# Docker Development\n\n> Smaller images. Faster builds. Secure containers. No guesswork.\n\nOpinionated Docker workflow that turns bloated Dockerfiles into production-grade containers. Covers optimization, multi-stage builds, compose orchestration, and security hardening.\n\nNot a Docker tutorial — a set of concrete decisions about how to build containers that don't waste time, space, or attack surface.\n\n---\n\n## Slash Commands\n\n| Command | What it does |\n|---------|-------------|\n| `\u002Fdocker:optimize` | Analyze and optimize a Dockerfile for size, speed, and layer caching |\n| `\u002Fdocker:compose` | Generate or improve docker-compose.yml with best practices |\n| `\u002Fdocker:security` | Audit a Dockerfile or running container for security issues |\n\n---\n\n## When This Skill Activates\n\nRecognize these patterns from the user:\n\n- \"Optimize this Dockerfile\"\n- \"My Docker build is slow\"\n- \"Create a docker-compose for this project\"\n- \"Is this Dockerfile secure?\"\n- \"Reduce my Docker image size\"\n- \"Set up multi-stage builds\"\n- \"Docker best practices for [language\u002Fframework]\"\n- Any request involving: Dockerfile, docker-compose, container, image size, build cache, Docker security\n\nIf the user has a Dockerfile or wants to containerize something → this skill applies.\n\n---\n\n## Workflow\n\n### `\u002Fdocker:optimize` — Dockerfile Optimization\n\n1. **Analyze current state**\n   - Read the Dockerfile\n   - Identify base image and its size\n   - Count layers (each RUN\u002FCOPY\u002FADD = 1 layer)\n   - Check for common anti-patterns\n\n2. **Apply optimization checklist**\n\n   ```\n   BASE IMAGE\n   ├── Use specific tags, never :latest in production\n   ├── Prefer slim\u002Falpine variants (debian-slim > ubuntu > debian)\n   ├── Pin digest for reproducibility in CI: image@sha256:...\n   └── Match base to runtime needs (don't use python:3.12 for a compiled binary)\n\n   LAYER OPTIMIZATION\n   ├── Combine related RUN commands with && \\\n   ├── Order layers: least-changing first (deps before source code)\n   ├── Clean package manager cache in the same RUN layer\n   ├── Use .dockerignore to exclude unnecessary files\n   └── Separate build deps from runtime deps\n\n   BUILD CACHE\n   ├── COPY dependency files before source code (package.json, requirements.txt, go.mod)\n   ├── Install deps in a separate layer from code copy\n   ├── Use BuildKit cache mounts: --mount=type=cache,target=\u002Froot\u002F.cache\n   └── Avoid COPY . . before dependency installation\n\n   MULTI-STAGE BUILDS\n   ├── Stage 1: build (full SDK, build tools, dev deps)\n   ├── Stage 2: runtime (minimal base, only production artifacts)\n   ├── COPY --from=builder only what's needed\n   └── Final image should have NO build tools, NO source code, NO dev deps\n   ```\n\n3. **Generate optimized Dockerfile**\n   - Apply all relevant optimizations\n   - Add inline comments explaining each decision\n   - Report estimated size reduction\n\n4. **Validate**\n   ```bash\n   python3 scripts\u002Fdockerfile_analyzer.py Dockerfile\n   ```\n\n### `\u002Fdocker:compose` — Docker Compose Configuration\n\n1. **Identify services**\n   - Application (web, API, worker)\n   - Database (postgres, mysql, redis, mongo)\n   - Cache (redis, memcached)\n   - Queue (rabbitmq, kafka)\n   - Reverse proxy (nginx, traefik, caddy)\n\n2. **Apply compose best practices**\n\n   ```\n   SERVICES\n   ├── Use depends_on with condition: service_healthy\n   ├── Add healthchecks for every service\n   ├── Set resource limits (mem_limit, cpus)\n   ├── Use named volumes for persistent data\n   └── Pin image versions\n\n   NETWORKING\n   ├── Create explicit networks (don't rely on default)\n   ├── Separate frontend and backend networks\n   ├── Only expose ports that need external access\n   └── Use internal: true for backend-only networks\n\n   ENVIRONMENT\n   ├── Use env_file for secrets, not inline environment\n   ├── Never commit .env files (add to .gitignore)\n   ├── Use variable substitution: ${VAR:-default}\n   └── Document all required env vars\n\n   DEVELOPMENT vs PRODUCTION\n   ├── Use compose profiles or override files\n   ├── Dev: bind mounts for hot reload, debug ports exposed\n   ├── Prod: named volumes, no debug ports, restart: unless-stopped\n   └── docker-compose.override.yml for dev-only config\n   ```\n\n3. **Generate compose file**\n   - Output docker-compose.yml with healthchecks, networks, volumes\n   - Generate .env.example with all required variables documented\n   - Add dev\u002Fprod profile annotations\n\n### `\u002Fdocker:security` — Container Security Audit\n\n1. **Dockerfile audit**\n\n   | Check | Severity | Fix |\n   |-------|----------|-----|\n   | Running as root | Critical | Add `USER nonroot` after creating user |\n   | Using :latest tag | High | Pin to specific version |\n   | Secrets in ENV\u002FARG | Critical | Use BuildKit secrets: `--mount=type=secret` |\n   | COPY with broad glob | Medium | Use specific paths, add .dockerignore |\n   | Unnecessary EXPOSE | Low | Only expose ports the app uses |\n   | No HEALTHCHECK | Medium | Add HEALTHCHECK with appropriate interval |\n   | Privileged instructions | High | Avoid `--privileged`, drop capabilities |\n   | Package manager cache retained | Low | Clean in same RUN layer |\n\n2. **Runtime security checks**\n\n   | Check | Severity | Fix |\n   |-------|----------|-----|\n   | Container running as root | Critical | Set user in Dockerfile or compose |\n   | Writable root filesystem | Medium | Use `read_only: true` in compose |\n   | All capabilities retained | High | Drop all, add only needed: `cap_drop: [ALL]` |\n   | No resource limits | Medium | Set `mem_limit` and `cpus` |\n   | Host network mode | High | Use bridge or custom network |\n   | Sensitive mounts | Critical | Never mount \u002Fetc, \u002Fvar\u002Frun\u002Fdocker.sock in prod |\n   | No log driver configured | Low | Set `logging:` with size limits |\n\n3. **Generate security report**\n   ```\n   SECURITY AUDIT — [Dockerfile\u002FImage name]\n   Date: [timestamp]\n\n   CRITICAL: [count]\n   HIGH:     [count]\n   MEDIUM:   [count]\n   LOW:      [count]\n\n   [Detailed findings with fix recommendations]\n   ```\n\n---\n\n## Tooling\n\n### `scripts\u002Fdockerfile_analyzer.py`\n\nCLI utility for static analysis of Dockerfiles.\n\n**Features:**\n- Layer count and optimization suggestions\n- Base image analysis with size estimates\n- Anti-pattern detection (15+ rules)\n- Security issue flagging\n- Multi-stage build detection and validation\n- JSON and text output\n\n**Usage:**\n```bash\n# Analyze a Dockerfile\npython3 scripts\u002Fdockerfile_analyzer.py Dockerfile\n\n# JSON output\npython3 scripts\u002Fdockerfile_analyzer.py Dockerfile --output json\n\n# Analyze with security focus\npython3 scripts\u002Fdockerfile_analyzer.py Dockerfile --security\n\n# Check a specific directory\npython3 scripts\u002Fdockerfile_analyzer.py path\u002Fto\u002FDockerfile\n```\n\n### `scripts\u002Fcompose_validator.py`\n\nCLI utility for validating docker-compose files.\n\n**Features:**\n- Service dependency validation\n- Healthcheck presence detection\n- Network configuration analysis\n- Volume mount validation\n- Environment variable audit\n- Port conflict detection\n- Best practice scoring\n\n**Usage:**\n```bash\n# Validate a compose file\npython3 scripts\u002Fcompose_validator.py docker-compose.yml\n\n# JSON output\npython3 scripts\u002Fcompose_validator.py docker-compose.yml --output json\n\n# Strict mode (fail on warnings)\npython3 scripts\u002Fcompose_validator.py docker-compose.yml --strict\n```\n\n---\n\n## Multi-Stage Build Patterns\n\n### Pattern 1: Compiled Language (Go, Rust, C++)\n\n```dockerfile\n# Build stage\nFROM golang:1.22-alpine AS builder\nWORKDIR \u002Fapp\nCOPY go.mod go.sum .\u002F\nRUN go mod download\nCOPY . .\nRUN CGO_ENABLED=0 go build -ldflags=\"-s -w\" -o \u002Fapp\u002Fserver .\u002Fcmd\u002Fserver\n\n# Runtime stage\nFROM gcr.io\u002Fdistroless\u002Fstatic-debian12\nCOPY --from=builder \u002Fapp\u002Fserver \u002Fserver\nUSER nonroot:nonroot\nENTRYPOINT [\"\u002Fserver\"]\n```\n\n### Pattern 2: Node.js \u002F TypeScript\n\n```dockerfile\n# Dependencies stage\nFROM node:20-alpine AS deps\nWORKDIR \u002Fapp\nCOPY package.json package-lock.json .\u002F\nRUN npm ci --production=false\n\n# Build stage\nFROM deps AS builder\nCOPY . .\nRUN npm run build\n\n# Runtime stage\nFROM node:20-alpine\nWORKDIR \u002Fapp\nRUN addgroup -g 1001 -S appgroup && adduser -S appuser -u 1001\nCOPY --from=builder \u002Fapp\u002Fdist .\u002Fdist\nCOPY --from=deps \u002Fapp\u002Fnode_modules .\u002Fnode_modules\nCOPY package.json .\u002F\nUSER appuser\nEXPOSE 3000\nCMD [\"node\", \"dist\u002Findex.js\"]\n```\n\n### Pattern 3: Python\n\n```dockerfile\n# Build stage\nFROM python:3.12-slim AS builder\nWORKDIR \u002Fapp\nCOPY requirements.txt .\nRUN pip install --no-cache-dir --prefix=\u002Finstall -r requirements.txt\n\n# Runtime stage\nFROM python:3.12-slim\nWORKDIR \u002Fapp\nRUN groupadd -r appgroup && useradd -r -g appgroup appuser\nCOPY --from=builder \u002Finstall \u002Fusr\u002Flocal\nCOPY . .\nUSER appuser\nEXPOSE 8000\nCMD [\"python\", \"-m\", \"uvicorn\", \"main:app\", \"--host\", \"0.0.0.0\", \"--port\", \"8000\"]\n```\n\n---\n\n## Base Image Decision Tree\n\n```\nIs it a compiled binary (Go, Rust, C)?\n├── Yes → distroless\u002Fstatic or scratch\n└── No\n    ├── Need a shell for debugging?\n    │   ├── Yes → alpine variant (e.g., node:20-alpine)\n    │   └── No → distroless variant\n    ├── Need glibc (not musl)?\n    │   ├── Yes → slim variant (e.g., python:3.12-slim)\n    │   └── No → alpine variant\n    └── Need specific OS packages?\n        ├── Many → debian-slim\n        └── Few → alpine + apk add\n```\n\n---\n\n## Proactive Triggers\n\nFlag these without being asked:\n\n- **Dockerfile uses :latest** → Suggest pinning to a specific version tag.\n- **No .dockerignore** → Create one. At minimum: `.git`, `node_modules`, `__pycache__`, `.env`.\n- **COPY . . before dependency install** → Cache bust. Reorder to install deps first.\n- **Running as root** → Add USER instruction. No exceptions for production.\n- **Secrets in ENV or ARG** → Use BuildKit secret mounts. Never bake secrets into layers.\n- **Image over 1GB** → Multi-stage build required. No reason for a production image this large.\n- **No healthcheck** → Add one. Orchestrators (Compose, K8s) need it for proper lifecycle management.\n- **apt-get without cleanup in same layer** → `rm -rf \u002Fvar\u002Flib\u002Fapt\u002Flists\u002F*` in the same RUN.\n\n---\n\n## Installation\n\n### One-liner (any tool)\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Falirezarezvani\u002Fclaude-skills.git\ncp -r claude-skills\u002Fengineering\u002Fdocker-development ~\u002F.claude\u002Fskills\u002F\n```\n\n### Multi-tool install\n```bash\n.\u002Fscripts\u002Fconvert.sh --skill docker-development --tool codex|gemini|cursor|windsurf|openclaw\n```\n\n### OpenClaw\n```bash\nclawhub install cs-docker-development\n```\n\n---\n\n## Related Skills\n\n- **senior-devops** — Broader DevOps scope (CI\u002FCD, IaC, monitoring). Complementary — use docker-development for container-specific work, senior-devops for pipeline and infrastructure.\n- **senior-security** — Application security. Complementary — docker-development covers container security, senior-security covers application-level threats.\n- **autoresearch-agent** — Can optimize Docker build times or image sizes as measurable experiments.\n- **ci-cd-pipeline-builder** — Pipeline construction. Complementary — docker-development builds the containers, ci-cd-pipeline-builder deploys them.\n",{"name":5,"license":14,"metadata":23,"description":7},{"author":24,"updated":25,"version":26,"category":27},"Alireza Rezvani",1773619200000,"1.0.0","engineering","main","b4ebd6d8c3b36347a5d435bcb343a5fc1c6f08d1","skills-library\u002Fengineering\u002Fdocker-development\u002Fskills\u002Fdocker-development","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE","https:\u002F\u002Fgithub.com\u002FTehutiRaEl","2026-11-15 04:00:21",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":46},[36,39,42],{"tool":37,"command":38},"npx","npx skills add TehutiRaEl\u002FTHEHIVE --skill docker-development",{"tool":40,"command":41},"bunx","bunx skills add TehutiRaEl\u002FTHEHIVE --skill docker-development",{"tool":43,"command":44},"pnpm","pnpm dlx skills add TehutiRaEl\u002FTHEHIVE --skill docker-development","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fengineering\u002Fdocker-development\u002Fskills\u002Fdocker-development\u002FSKILL.md",true,[48,54,58,64],{"path":49,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":52,"sourceHtmlUrl":53},"references\u002Fcompose-patterns.md","REFERENCE","参考文档",5877,"https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fengineering\u002Fdocker-development\u002Fskills\u002Fdocker-development\u002Freferences\u002Fcompose-patterns.md",{"path":55,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":56,"sourceHtmlUrl":57},"references\u002Fdockerfile-best-practices.md",5243,"https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fengineering\u002Fdocker-development\u002Fskills\u002Fdocker-development\u002Freferences\u002Fdockerfile-best-practices.md",{"path":59,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":62,"sourceHtmlUrl":63},"scripts\u002Fcompose_validator.py","SCRIPT","脚本",13506,"https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fengineering\u002Fdocker-development\u002Fskills\u002Fdocker-development\u002Fscripts\u002Fcompose_validator.py",{"path":65,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":66,"sourceHtmlUrl":67},"scripts\u002Fdockerfile_analyzer.py",13870,"https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fengineering\u002Fdocker-development\u002Fskills\u002Fdocker-development\u002Fscripts\u002Fdockerfile_analyzer.py",[69,76,82,89,96,103],{"skillNo":70,"name":71,"nameZh":6,"description":72,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":75,"publishedAt":18},"01M76XP63XDM4PFPX8MMVYN9JX","preamble-gate","Use BEFORE doing any work in this repo — before the first file edit, commit, push, PR, branch operation, workflow dispatch, scheduled trigger or timer, agent\u002Fsubagent spawn, dependency install, or message sent to an outside service. Forces a plain-language preamble to the founder first: WHAT you are about to do, WHY, HOW, why it is NECESSARY, the PROJECTED IMPROVEMENT, and the COST and RISK — then, for consequential work (governance, security, money, CI\u002Ftriggers, rewriting history, multi-agent fan-out), waits for an explicit go-ahead. Read-only investigation (reading files, grep, git log\u002Fdiff, answering questions) is exempt. Applies to every AI that works in this repo, not just Claude. Founder rule, 2026-11-10, written after an unattended automation ran up cost and froze the hive. Not a substitute for wired-or-not (which governs how completion is CLAIMED); this governs what happens BEFORE work starts.","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fpreamble-gate\u002FSKILL.md",[],[],{"skillNo":77,"name":78,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":18},"01M75RAYXC1W361YR9NBXD59AM","visionary-recommender","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills\u002Fvisionary-recommender\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":18},"01M75RAQN9Q450RD57J2S6FSR4","syllabus","Generates a curated supplementary reading list from any course syllabus using Consensus academic search. Grill-me intake (syllabus input format + course audience + year range) plus a grouping forcing-options checkpoint before any search runs — so the reading list matches the course's level and recency need. Parses the syllabus to extract topics and learning outcomes, searches Consensus for recent peer-reviewed papers per topic, and produces a professionally formatted .docx with clickable Consensus links, plain-language summaries calibrated to audience level, and Bloom-higher-order discussion questions tied to course learning goals. Use when the user uploads a syllabus, course outline, or curriculum document and wants supplementary readings (e.g., 'create a reading list from this syllabus', 'find recent papers for my course') — even casual mentions with a syllabus attached should trigger this skill.","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fresearch\u002Fsyllabus\u002Fskills\u002Fsyllabus\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":18},"01M75RAG1XMCJMF30HFV5S79AK","research","Default entry point for any research request — a hybrid router that classifies the question deterministically and either delegates to a specialist research skill (pulse for trends\u002Fsentiment, grants for NIH funding, litreview for academic literature, syllabus for course reading, patent for prior-art + IP landscape, dossier for entity research) or runs its own plan-decompose-multi-source-search-synthesize-cite fallback workflow when no specialist matches. Always surfaces the routing decision so users can override. Use when the user makes any research request that doesn't obviously match a more-specific specialist skill (e.g., \"research [topic]\", \"look into [topic]\", \"what do we know about [topic]\", \"investigate [topic]\", \"find me information on [topic]\", \"do some research on [topic]\", \"I need to understand [topic]\"). Output is a markdown briefing (default) or .docx document (on request) with full citations and an audit log.","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fresearch\u002Fresearch\u002Fskills\u002Fresearch\u002FSKILL.md",[],[],{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":18},"01M75RA8RK2JVWB8MYGRB65V75","pulse","Multi-source recency research skill that takes the pulse of any topic across Reddit, Hacker News, the open web, and optionally X\u002FTwitter within a configurable recent window (default 30 days). Forcing intake clarifies topic specificity, angle (trend\u002Fsentiment\u002Fproblems\u002Fopportunities\u002Fcomparison), time window, and platform scope before searching. Returns a synthesized briefing with citations, engagement metrics, and cross-platform pattern analysis. Use when the user requests multi-source recency intelligence on a topic (e.g., 'pulse on [topic]', 'what's happening with [topic]', 'what are people saying about [topic]', 'current conversation about [topic]', 'take the pulse of [topic]', 'trending: [topic]', 'find me info on [topic]'), and for competitor research, trend discovery, tool comparisons, and audience sentiment analysis.","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fresearch\u002Fpulse\u002Fskills\u002Fpulse\u002FSKILL.md",[],[],{"skillNo":104,"name":105,"nameZh":6,"description":106,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":107,"categories":108,"keywords":109,"publishedAt":18},"01M75RA08RXYRFSTNC6EEEX4ZD","patent","Patent prior-art and landscape intelligence skill — not generic patent help. Commits to one of five sub-use-cases via forcing intake (novelty search \u002F freedom-to-operate \u002F competitive landscape \u002F acquisition diligence \u002F litigation prior-art) before any search runs. Searches Google Patents, Espacenet, USPTO, and optionally Lens.org for citation-graph signals. Output is an editable Word document (.docx) with verdict, ranked closest art (claim-text extracted), CPC-class-aware landscape, family-resolved hits, geographic coverage, FTO flags where applicable, strategy recommendations, and full audit log. Use when the user asks for patent searching or analysis (e.g., 'prior art search for [invention]', 'freedom to operate analysis for [product]'). Produces search signal, not legal advice — always recommends consulting a patent attorney before filing or licensing decisions. Trademark, copyright, and trade-secret questions are out of scope.","https:\u002F\u002Fgithub.com\u002FTehutiRaEl\u002FTHEHIVE\u002Fblob\u002Fmain\u002Fskills-library\u002Fresearch\u002Fpatent\u002Fskills\u002Fpatent\u002FSKILL.md",[],[]]