docker-development
하는 일
이 스킬은 Docker 컨테이너 설정을 작성하고, 최적화하고, 검토하도록 안내합니다. 빨리 빌드되고, 크기가 작고, 안전하게 실행되는 컨테이너를 원하는 개발자에게 맞습니다.
사용하는 경우
- ✓Docker 빌드가 느리거나 이미지가 너무 클 때.
- ✓프로젝트를 위해 docker-compose 파일을 설정하고 싶을 때.
- ✓배포하기 전에 Dockerfile에 보안 문제가 있는지 확인하고 싶을 때.
스킬 링크
https://github.com/alirezarezvani/claude-skills/blob/main/engineering/docker-development/skills/docker-development/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“Docker 이미지가 너무 크고 빌드가 느립니다. 크기와 캐싱에 맞게 Dockerfile을 최적화해 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
에이전트는 Dockerfile의 레이어, 캐시, 크기를 분석한 뒤 멀티 스테이지 빌드 같은 변경을 제안합니다. compose 파일도 검증하고, Dockerfile이나 실행 중인 컨테이너의 보안 문제를 점검합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
Docker Development
Smaller images. Faster builds. Secure containers. No guesswork.
Opinionated Docker workflow that turns bloated Dockerfiles into production-grade containers. Covers optimization, multi-stage builds, compose orchestration, and security hardening.
Not a Docker tutorial — a set of concrete decisions about how to build containers that don't waste time, space, or attack surface.
Slash Commands
| Command | What it does |
|---|---|
/docker-development optimize |
Analyze and optimize a Dockerfile for size, speed, and layer caching |
/docker-development compose |
Generate or improve docker-compose.yml with best practices |
/docker-development security |
Audit a Dockerfile or running container for security issues |
When This Skill Activates
Recognize these patterns from the user:
- "Optimize this Dockerfile"
- "My Docker build is slow"
- "Create a docker-compose for this project"
- "Is this Dockerfile secure?"
- "Reduce my Docker image size"
- "Set up multi-stage builds"
- "Docker best practices for [language/framework]"
- Any request involving: Dockerfile, docker-compose, container, image size, build cache, Docker security
If the user has a Dockerfile or wants to containerize something → this skill applies.
Workflow
/docker-development optimize — Dockerfile Optimization
Analyze current state
- Read the Dockerfile
- Identify base image and its size
- Count layers (each RUN/COPY/ADD = 1 layer)
- Check for common anti-patterns
Apply optimization checklist
BASE IMAGE ├── Use specific tags, never :latest in production ├── Prefer slim/alpine variants (debian-slim > ubuntu > debian) ├── Pin digest for reproducibility in CI: image@sha256:... └── Match base to runtime needs (don't use python:3.12 for a compiled binary) LAYER OPTIMIZATION ├── Combine related RUN commands with && \ ├── Order layers: least-changing first (deps before source code) ├── Clean package manager cache in the same RUN layer ├── Use .dockerignore to exclude unnecessary files └── Separate build deps from runtime deps BUILD CACHE ├── COPY dependency files before source code (package.json, requirements.txt, go.mod) ├── Install deps in a separate layer from code copy ├── Use BuildKit cache mounts: --mount=type=cache,target=/root/.cache └── Avoid COPY . . before dependency installation MULTI-STAGE BUILDS ├── Stage 1: build (full SDK, build tools, dev deps) ├── Stage 2: runtime (minimal base, only production artifacts) ├── COPY --from=builder only what's needed └── Final image should have NO build tools, NO source code, NO dev depsGenerate optimized Dockerfile
- Apply all relevant optimizations
- Add inline comments explaining each decision
- Report estimated size reduction
Validate
python3 scripts/dockerfile_analyzer.py Dockerfile
/docker-development compose — Docker Compose Configuration
Identify services
- Application (web, API, worker)
- Database (postgres, mysql, redis, mongo)
- Cache (redis, memcached)
- Queue (rabbitmq, kafka)
- Reverse proxy (nginx, traefik, caddy)
Apply compose best practices
SERVICES ├── Use depends_on with condition: service_healthy ├── Add healthchecks for every service ├── Set resource limits (mem_limit, cpus) ├── Use named volumes for persistent data └── Pin image versions NETWORKING ├── Create explicit networks (don't rely on default) ├── Separate frontend and backend networks ├── Only expose ports that need external access └── Use internal: true for backend-only networks ENVIRONMENT ├── Use env_file for secrets, not inline environment ├── Never commit .env files (add to .gitignore) ├── Use variable substitution: ${VAR:-default} └── Document all required env vars DEVELOPMENT vs PRODUCTION ├── Use compose profiles or override files ├── Dev: bind mounts for hot reload, debug ports exposed ├── Prod: named volumes, no debug ports, restart: unless-stopped └── docker-compose.override.yml for dev-only configGenerate compose file
- Output docker-compose.yml with healthchecks, networks, volumes
- Generate .env.example with all required variables documented
- Add dev/prod profile annotations
/docker-development security — Container Security Audit
- **Dockerfile
자주 묻는 질문
멀티 스테이지 빌드란 무엇인가요?
앱을 빌드하는 단계와 실행하는 더 작은 단계를 나눈 Dockerfile입니다. 최종 이미지가 더 가벼워집니다.
실행 중인 컨테이너도 점검할 수 있나요?
네. 보안 명령으로 Dockerfile이나 실행 중인 컨테이너를 점검할 수 있습니다.
docker-compose에도 도움이 되나요?
네. 모범 사례를 따르는 docker-compose 파일을 만들거나 개선할 수 있습니다.
상세 정보
작성자의 원본 설명
Use for any Dockerfile or docker-compose file to write, optimize or review, before editing it. Checks layers, caching, size and security with dockerfile_analyzer.py and validates compose files with compose_validator.py.
인기도
- GitHub 스타
- 29k
- 순위
- #9555
- 라이선스
- MIT
- 업데이트
- 2026. 11. 2.
댓글
- …
이 저장소의 다른 스킬
agent-launcher-orchestrator
29k하나의 명확한 목표에서 시작해 내 계정의 Claude 관리형 에이전트를 계획하고, 만들고, 테스트하고, 예약하도록 돕습니다.
grade-iterate
29k에이전트가 채점 기준표에 따라 관리형 AI 에이전트의 결과물을 평가하고, 정해진 횟수 안에서 개선하도록 돕습니다. 끝없이 반복하지 않습니다.
interview
29kAI 에이전트 아이디어에 대해 질문하고, 답변을 간단한 빌드 계획으로 바꿔 어떤 것도 출시하기 전에 정리하도록 돕습니다.
run-without-you
29k에이전트가 관리형 AI 에이전트를 예약 또는 이벤트에 따라 실행되도록 설정하고, 출시 전에 cron 시간을 확인하도록 돕습니다.
비슷한 스킬
openclaw-update
394k에이전트가 설치 방식에 맞는 방법을 골라 기존 OpenClaw Gateway를 업데이트하고, 세션이 계속 작동하도록 돕습니다.
diagnose-gateway
394k에이전트가 설정, 채널, 포트를 확인해 OpenClaw Gateway가 왜 실패하는지 찾되, 아무것도 바꾸지 않도록 돕습니다.
crabbox-apps
394k에이전트가 임시 클라우드 머신에서 앱을 열고 실행한 뒤, 그 화면을 채팅의 측면 패널에 보여 주도록 돕습니다.