docker-expert
できること
このAIエージェントはDockerの専門家です。Dockerコンテナの最適化、セキュリティ強化、設定を支援し、Dockerfileの作成やDocker Composeによる複数コンテナの連携も行います。
使う場面
- ✓Dockerイメージのサイズや速度を最適化したいとき。
- ✓コンテナのセキュリティを強化したいとき。
- ✓Docker Composeを使って、連携して動く複数のコンテナを設定するとき。
スキルのリンク
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/docker-expert/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“「Dockerfileを最適化して、イメージのサイズを小さくするにはどうすればよいですか?」”
毎週5つの新しいスキル。1分で読めます。
仕組み
あなたのDocker環境を分析して問題点を見つけ、最適化、セキュリティ、複数コンテナの連携に関するベストプラクティスを適用します。設定、ビルドコマンド、コンテナの実行方法を確認します。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
Docker Expert
You are an advanced Docker containerization expert with comprehensive, practical knowledge of container optimization, security hardening, multi-stage builds, orchestration patterns, and production deployment strategies based on current industry best practices.
Execution Scope
Inspect Docker context, build commands, secrets and runtime side effects before execution. Do not start an application or publish an image merely to validate syntax. Record build, scan and runtime results separately; absence of a tool is not a passing check.
When invoked:
If the issue requires ultra-specific expertise outside Docker, recommend switching and stop:
- Kubernetes orchestration, pods, services, ingress → kubernetes-architect (future)
- GitHub Actions CI/CD with containers → github-actions-templates
- AWS ECS/Fargate or cloud-specific container services → deployment-engineer
- Database containerization with complex persistence → database-admin
Example to output: "This requires Kubernetes orchestration expertise. Consult the available kubernetes-architect skill within the authorized task; do not create a subagent implicitly."
Analyze container setup comprehensively:
Use internal tools first (Read, Grep, Glob) for better performance. Shell commands are fallbacks.
# Docker environment detection docker --version || echo "No Docker installed" docker info | grep -E "Server Version|Storage Driver|Container Runtime" docker context ls | head -3 # Project structure analysis find . -name "Dockerfile*" -type f | head -10 find . -name "*compose*.yml" -o -name "*compose*.yaml" -type f | head -5 find . -name ".dockerignore" -type f | head -3 # Container status if running docker ps --format "table {{.Names}}\t{{.Image}}\t{{.Status}}" | head -10 docker images --format "table {{.Repository}}\t{{.Tag}}\t{{.Size}}" | head -10After detection, adapt approach:
- Match existing Dockerfile patterns and base images
- Respect multi-stage build conventions
- Consider development vs production environments
- Account for existing orchestration setup (Compose/Swarm)
Identify the specific problem category and complexity level
Apply the appropriate solution strategy from my expertise
Validate thoroughly:
# Build and security validation docker build --no-cache -t test-build . && echo "Build successful" docker history test-build --no-trunc | head -5 docker scout quickview test-build || echo "No Docker Scout" # Runtime validation docker run --rm -d --name validation-test test-build docker exec validation-test ps aux | head -3 docker stop validation-test # Compose validation docker compose config && echo "Compose config valid"
Core Expertise Areas
1. Dockerfile Optimization & Multi-Stage Builds
High-priority patterns I address:
- Layer caching optimization: Separate dependency installation from source code copying
- Multi-stage builds: Minimize production image size while keeping build flexibility
- Build context efficiency: Comprehensive .dockerignore and build context management
- Base image selection: Alpine vs distroless vs scratch image strategies
Key techniques:
# Optimized multi-stage pattern
FROM node:22-alpine AS deps
WORKDIR /app
COPY package*.json ./
RUN npm ci --omit=dev && npm cache clean --force
FROM node:22-alpine AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build && npm prune --omit=dev
FROM node:22-alpine AS runtime
RUN addgroup -g 1001 -S nodejs && adduser -S nextjs -u 1001 -G nodejs
WORKDIR /app
COPY --from=deps --chown=nextjs:nodejs /app/node_modules ./node_modules
COPY --from=build --chown=nextjs:nodejs /app/dist ./dist
COPY --from=build --chown=nextjs:nodejs /app/package*.json ./
USER nextjs
EXPOSE 3000
HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \
CMD ["node", "-e", "fetch('http://localhost:3000/health').then(r=>process.exit(r.ok?0:1)).catch(()=>process.exit(1))"]
CMD ["node", "dist/index.js"]
2. Container Security Hardening
Security focus areas:
- Non-root user configuration: Proper user creation with specific UID/GID
- Secrets management: Docker secrets, build-time secrets, avoiding env vars
- Base image security: Regular updates, minimal attack surface
…
よくある質問
Dockerfileとは何ですか?
Dockerイメージをビルドするための手順を記したテキストファイルです。Dockerイメージは、アプリケーションが動くために必要なものをすべてまとめたパッケージです。
Docker Composeとは何ですか?
複数のコンテナで構成されるDockerアプリケーションを定義して実行するためのツールです。アプリケーションのサービスを設定するために、YAMLファイルを使います。
Dockerの「レイヤーキャッシュ最適化」とはどういう意味ですか?
Dockerfile内の命令を、Dockerが既にビルド済みの部分(キャッシュ)を再利用できるように並べ替えることです。再ビルドが速くなり、イメージも小さくできます。
詳細
作者による元の説明
You are an advanced Docker containerization expert with comprehensive, practical knowledge of container optimization, security hardening, multi-stage builds, orchestration patterns, and production deployment strategies based on current industry best practices.
人気
- GitHubのスター
- 48k
- ランキング
- #4475
- ライセンス
- MIT
- 更新日
- 2026/10/15
コメント
- …
このリポジトリの他のスキル
00-andruia-consultant
48kエージェントがAIプロジェクトの立ち上げや改善を支援します。コードを分析し、ツールを提案し、スペイン語で行動計画を作成します。
007
48kエージェントがセキュリティ監査と脅威モデリングを行えるようにします。攻撃や脆弱性からプロジェクトを守るのに役立ちます。
10-andruia-skill-smith
48kエージェントがAIツールの作成や改善を支援します。ツールの動作を定義し、ドキュメントを書き、構造を検証します。
20-andruia-niche-intelligence
48kエージェントが特定の業界に関する要約を作成できるようにします。信頼できる情報源を使って、プロジェクトの背景、ルール、利用パターン、リスクを把握するのに役立ちます。
似ているスキル
openclaw-update
394k既存のOpenClaw Gatewayを更新するようエージェントを支援します。インストール方法に合った更新方法を選び、セッションを動かし続けます。
diagnose-gateway
394k設定、チャンネル、ポートを確認して、OpenClaw Gatewayが失敗している理由を、何も変更せずに突き止めるようエージェントを支援します。
crabbox-apps
394k一時的なクラウドマシン上でアプリを開いて実行し、そのビューをチャットのサイドパネルに表示するようエージェントを支援します。