depot-container-builds
できること
このスキルは、ローカルのDocker環境の代わりにDepotでコンテナ・イメージを作る流れを、AIエージェントに案内します。アプリをDockerイメージとしてまとめる開発者向けです。
使う場面
- ✓リモートのDepotビルダーでDockerイメージを作る必要があるとき。
- ✓IntelとARMの両方のコンピュータ向けに、1つのイメージを作りたいとき。
- ✓コンテナのビルドが失敗し、修正やキャッシュの高速化が必要なとき。
スキルのリンク
https://github.com/PostHog/posthog/blob/master/.agents/skills/depot-container-builds/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“Depotで私のアプリのDockerイメージを、IntelとARMの両方向けに作成し、レジストリにプッシュしてください。”
毎週5つの新しいスキル。1分で読めます。
仕組み
エージェントは、通常のDockerのビルドコマンドの代わりに、Depotのビルドコマンドを使います。ビルドはリモートのマシンで行われ、キャッシュは自動で処理されます。イメージは、ローカルのDockerに読み込む、プッシュする、保存するのいずれかができます。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
Depot Container Builds
Depot runs Docker image builds on remote high-performance builders (16 CPU, 32 GB RAM, NVMe SSD cache). depot build is a drop-in replacement for docker build / docker buildx build. depot bake replaces docker buildx bake.
Before you propose a change to CI, check things already tried for the idea. It records what was measured, and why some good-sounding changes were reverted or rejected.
<!-- End PostHog-local section. -->Project Selection for Multi-Org Users
Container build commands target a specific project, not an organization. If expected projects aren't visible or a build unexpectedly prompts to select a project, the current default org may be wrong:
depot org show # Current org ID
depot org list # Orgs the user belongs to
depot org switch <org-id> # Optional: set default org
Key Concepts
- Builds run remotely on ephemeral EC2 instances — images stay in remote cache by default
- Use
--loadto download to local Docker,--pushto push to a registry,--saveto store in Depot's ephemeral registry - Cache is fully automatic on persistent NVMe SSDs — no manual cache config needed
- Multi-platform builds use native CPU builders (no QEMU emulation) for amd64 and arm64 simultaneously
- All team members on a project share the same layer cache
depot build — Essential Patterns
# Build remotely (image stays in remote cache)
depot build -t repo/image:tag .
# Build + download to local Docker daemon
depot build -t repo/image:tag . --load
# Build + push directly to registry (fast — doesn't route through local network)
depot build -t repo/image:tag . --push
# Multi-platform build (native CPUs, no emulation)
depot build --platform linux/amd64,linux/arm64 -t repo/image:tag . --push
# Save to Depot ephemeral registry (7-day default, configurable per repository)
depot build --save .
depot build --save --save-tag my-tag .
# Suppress provenance metadata (fixes "unknown/unknown" platform in registries)
depot build -t repo/image:tag --push --provenance=false .
# Lint Dockerfile before building
depot build -t repo/image:tag . --lint
# Build with secrets
depot build --secret id=mysecret,src=./secret.txt -t repo/image:tag .
# Build with SSH forwarding
depot build --ssh default -t repo/image:tag .
# Specify a Depot project explicitly
depot build --project <project-id> -t repo/image:tag .
Key Flags
| Flag | Description |
|---|---|
--load |
Download image to local Docker daemon |
--push |
Push to registry |
--save |
Save to Depot ephemeral registry |
--save-tag |
Custom tag for Depot Registry |
--platform |
Target platforms: linux/amd64, linux/arm64 (native, no emulation), plus linux/arm/v6, linux/arm/v7, linux/386 |
--build-platform |
Force build to run on specific arch (dynamic default) |
--project |
Depot project ID |
--token |
Depot API token |
--lint |
Lint Dockerfile before build |
--provenance |
Control provenance attestation (set false to fix unknown/unknown) |
--sbom |
Generate an SBOM attestation (shorthand for --attest type=sbom) |
--sbom-dir |
D |
よくある質問
docker buildの代わりになりますか?
はい。このスキルは、depot buildがdocker buildの置き換えとして使え、depot bakeがdocker buildx bakeの代わりになると説明しています。
イメージはどこに保存されますか?
選んだオプションに応じて、ローカルのDockerに読み込む、レジストリにプッシュする、Depotのレジストリに保存する、のいずれかができます。
キャッシュの設定は必要ですか?
いいえ。Depotのビルダーではキャッシュが自動で行われる、とこのスキルは説明しています。
詳細
作者による元の説明
Configures and runs Depot remote container builds using `depot build` and `depot bake`. Use when building Docker images, creating Dockerfiles with Depot, pushing images to registries, building multi-platform/multi-arch images (linux/amd64, linux/arm64), debugging container build failures, optimizing Dockerfile layer caching, using docker-bake.hcl or docker-compose builds, or migrating from `docker build` / `docker buildx build` to Depot. Also use when the user mentions depot build, depot bake, container builds, image builds, or asks about Depot's build cache, build parallelism, build autoscali
repo: PostHog/posthog
人気
- GitHubのスター
- 41k
- ランキング
- #6811
- ライセンス
- —
- 更新日
- 2026/11/2
コメント
- …
このリポジトリの他のスキル
depot-ci
41kエージェントが、GitHub Actionsの代替であるDepot CIのワークフローを設定し実行できるよう支援します。既存のワークフローの移行や、実行ログの確認も含みます。
depot-github-runners
41kエージェントが、GitHub Actionsのジョブを Depot が管理するランナーに移し、ランナーのサイズとラベルを選び、ランナー設定の問題を解決できるよう支援します。
editing-agents-md
41kエージェントが、AGENTS.mdとCLAUDE.mdのどちらにルールを書くべきかを判断し、ファイルを膨らませずに守られやすい形で書けるよう支援します。
formatting-slack-messages
41kエージェントが、Slackの現在のルールに照らして、適切なレイアウトのメッセージ、モーダル、ホーム画面を作れるよう支援します。
似ているスキル
openclaw-update
394k既存のOpenClaw Gatewayを更新するようエージェントを支援します。インストール方法に合った更新方法を選び、セッションを動かし続けます。
diagnose-gateway
394k設定、チャンネル、ポートを確認して、OpenClaw Gatewayが失敗している理由を、何も変更せずに突き止めるようエージェントを支援します。
crabbox-apps
394k一時的なクラウドマシン上でアプリを開いて実行し、そのビューをチャットのサイドパネルに表示するようエージェントを支援します。