opencode-skills-collection 3.1.23 → 4.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundled-skills/.antigravity-install-manifest.json +24 -1
- package/bundled-skills/007/SKILL.md +2 -2
- package/bundled-skills/10-andruia-skill-smith/SKILL.md +1 -1
- package/bundled-skills/agent-squad/SKILL.md +5 -0
- package/bundled-skills/agent-squad/alex/SKILL.md +3 -0
- package/bundled-skills/agent-squad/aria/SKILL.md +3 -0
- package/bundled-skills/agent-squad/dep/SKILL.md +3 -0
- package/bundled-skills/agent-squad/luna/SKILL.md +4 -1
- package/bundled-skills/agent-squad/mason/SKILL.md +3 -0
- package/bundled-skills/agent-squad/max/SKILL.md +3 -0
- package/bundled-skills/agent-squad/quinn/SKILL.md +3 -0
- package/bundled-skills/agent-squad/rex/SKILL.md +3 -0
- package/bundled-skills/angular/metadata.json +1 -1
- package/bundled-skills/angular-best-practices/metadata.json +1 -1
- package/bundled-skills/angular-state-management/metadata.json +1 -1
- package/bundled-skills/angular-ui-patterns/metadata.json +1 -1
- package/bundled-skills/antigravity-skill-orchestrator/SKILL.md +2 -2
- package/bundled-skills/apify-actor-development/SKILL.md +2 -2
- package/bundled-skills/apple-container/SKILL.md +165 -0
- package/bundled-skills/apple-container/references/commands.md +1593 -0
- package/bundled-skills/apple-container/references/concepts.md +294 -0
- package/bundled-skills/apple-container/references/configuration.md +499 -0
- package/bundled-skills/apple-container/references/workflows.md +498 -0
- package/bundled-skills/ask-copilot/SKILL.md +112 -0
- package/bundled-skills/auto-research/SKILL.md +126 -0
- package/bundled-skills/brooks-lint/SKILL.md +1 -1
- package/bundled-skills/browser-harness/references/install.md +3 -1
- package/bundled-skills/chrome-extension-developer/SKILL.md +1 -1
- package/bundled-skills/clean-code-guard/SKILL.md +184 -0
- package/bundled-skills/clean-code-guard/references/ai-failure-modes.md +345 -0
- package/bundled-skills/clean-code-guard/references/comments-and-formatting.md +115 -0
- package/bundled-skills/clean-code-guard/references/dry-kiss-yagni.md +133 -0
- package/bundled-skills/clean-code-guard/references/naming-and-functions.md +187 -0
- package/bundled-skills/clean-code-guard/references/review-checklist.md +150 -0
- package/bundled-skills/clean-code-guard/references/solid.md +280 -0
- package/bundled-skills/clean-code-guard/references/sources.md +47 -0
- package/bundled-skills/cloudflare-security-audit/SKILL.md +137 -0
- package/bundled-skills/cloudflare-security-audit/references/AI-AND-LLM.md +67 -0
- package/bundled-skills/cloudflare-security-audit/references/ATTACK-CLASSES.md +116 -0
- package/bundled-skills/cloudflare-security-audit/references/CLIENT-SIDE.md +67 -0
- package/bundled-skills/cloudflare-security-audit/references/HUNTING.md +110 -0
- package/bundled-skills/cloudflare-security-audit/references/MEMORY-SAFETY-AND-BINARY.md +58 -0
- package/bundled-skills/cloudflare-security-audit/references/RECONNAISSANCE.md +46 -0
- package/bundled-skills/cloudflare-security-audit/references/VALIDATION-AND-REPORTING.md +109 -0
- package/bundled-skills/cloudflare-security-audit/references/WEB-PROTOCOL-AND-AUTH.md +85 -0
- package/bundled-skills/cloudflare-security-audit/resources/report-schema.json +210 -0
- package/bundled-skills/comfyui-gateway/references/troubleshooting.md +1 -1
- package/bundled-skills/commit/SKILL.md +2 -1
- package/bundled-skills/deepapi/SKILL.md +6 -6
- package/bundled-skills/docs/README.md +1 -1
- package/bundled-skills/docs/contributors/quality-bar.md +1 -1
- package/bundled-skills/docs/contributors/security-guardrails.md +1 -1
- package/bundled-skills/docs/integrations/jetski-cortex.md +5 -5
- package/bundled-skills/docs/integrations/jetski-gemini-loader/README.md +3 -3
- package/bundled-skills/docs/maintainers/ci-drift-fix.md +7 -5
- package/bundled-skills/docs/maintainers/merge-batch.md +24 -7
- package/bundled-skills/docs/maintainers/pr-autonomy.md +89 -0
- package/bundled-skills/docs/maintainers/release-notes-7.2.0.md +1 -1
- package/bundled-skills/docs/maintainers/release-process.md +9 -9
- package/bundled-skills/docs/maintainers/repo-growth-seo.md +5 -5
- package/bundled-skills/docs/maintainers/skills-date-tracking.md +1 -1
- package/bundled-skills/docs/maintainers/skills-update-guide.md +2 -2
- package/bundled-skills/docs/users/{antigravity-awesome-skills-vs-awesome-claude-skills.md → agentic-awesome-skills-vs-awesome-claude-skills.md} +5 -5
- package/bundled-skills/docs/users/ai-agent-skills.md +4 -4
- package/bundled-skills/docs/users/best-claude-code-skills-github.md +3 -3
- package/bundled-skills/docs/users/best-cursor-skills-github.md +3 -3
- package/bundled-skills/docs/users/bundles.md +56 -57
- package/bundled-skills/docs/users/claude-code-skills.md +6 -6
- package/bundled-skills/docs/users/codex-cli-skills.md +5 -5
- package/bundled-skills/docs/users/cursor-skills.md +3 -3
- package/bundled-skills/docs/users/faq.md +27 -15
- package/bundled-skills/docs/users/gemini-cli-skills.md +4 -4
- package/bundled-skills/docs/users/getting-started.md +22 -12
- package/bundled-skills/docs/users/kiro-integration.md +7 -7
- package/bundled-skills/docs/users/plugins.md +8 -9
- package/bundled-skills/docs/users/security-skills.md +1 -1
- package/bundled-skills/docs/users/skills-vs-mcp-tools.md +1 -1
- package/bundled-skills/docs/users/specialized-plugin-roadmap.md +3 -4
- package/bundled-skills/docs/users/usage.md +9 -9
- package/bundled-skills/docs/users/visual-guide.md +7 -7
- package/bundled-skills/docs/users/windows-truncation-recovery.md +1 -1
- package/bundled-skills/docs/users/workflows.md +1 -1
- package/bundled-skills/docs/vietnamese/BUNDLES.vi.md +1 -1
- package/bundled-skills/docs/vietnamese/FAQ.vi.md +15 -8
- package/bundled-skills/docs/vietnamese/GETTING_STARTED.vi.md +12 -5
- package/bundled-skills/docs/vietnamese/QUALITY_BAR.vi.md +1 -1
- package/bundled-skills/docs/vietnamese/README.vi.md +21 -17
- package/bundled-skills/docs/vietnamese/SECURITY_GUARDRAILS.vi.md +1 -1
- package/bundled-skills/docs/vietnamese/SKILLS_README.vi.md +2 -2
- package/bundled-skills/docs/vietnamese/TRANSLATION_PLAN.vi.md +1 -1
- package/bundled-skills/docs/vietnamese/VISUAL_GUIDE.vi.md +8 -8
- package/bundled-skills/docs-guard/SKILL.md +109 -0
- package/bundled-skills/docs-guard/references/code-samples.md +46 -0
- package/bundled-skills/docs-guard/references/docstrings.md +60 -0
- package/bundled-skills/docs-guard/references/review-checklist.md +45 -0
- package/bundled-skills/docs-guard/references/sources.md +22 -0
- package/bundled-skills/docs-guard/references/verification.md +51 -0
- package/bundled-skills/efficient-web-research/SKILL.md +4 -0
- package/bundled-skills/electron-development/SKILL.md +1 -1
- package/bundled-skills/event-staffing-compliance/SKILL.md +3 -0
- package/bundled-skills/event-staffing-ordering/SKILL.md +3 -0
- package/bundled-skills/feature-tracking/SKILL.md +222 -0
- package/bundled-skills/flutter-expert/SKILL.md +6 -1
- package/bundled-skills/flutter-expert/resources/implementation-playbook.md +214 -0
- package/bundled-skills/gemini-deep-research/README.md +246 -0
- package/bundled-skills/gemini-deep-research/SKILL.md +136 -0
- package/bundled-skills/gemini-deep-research/requirements.txt +2 -0
- package/bundled-skills/gemini-deep-research/scripts/research.py +692 -0
- package/bundled-skills/git-pushing/SKILL.md +21 -4
- package/bundled-skills/git-pushing/scripts/smart_commit.sh +206 -11
- package/bundled-skills/go-in-depth/scripts/workflow-script.js +4 -1
- package/bundled-skills/grok-build/SKILL.md +167 -0
- package/bundled-skills/grok-build/references/cli.md +99 -0
- package/bundled-skills/huggingface-tool-builder/references/find_models_by_paper.sh +1 -1
- package/bundled-skills/idea-autopsy/SKILL.md +147 -0
- package/bundled-skills/it-manager-hospital/README.md +1 -1
- package/bundled-skills/it-manager-pro/README.md +1 -1
- package/bundled-skills/itil-expert/README.md +1 -1
- package/bundled-skills/langgraph/SKILL.md +1 -1
- package/bundled-skills/linkedin-content-generator/SKILL.md +1 -1
- package/bundled-skills/lint-and-validate/scripts/lint_runner.py +23 -23
- package/bundled-skills/lint-and-validate/scripts/type_coverage.py +30 -30
- package/bundled-skills/logic-lens/SKILL.md +1 -1
- package/bundled-skills/lore/LICENSE +21 -0
- package/bundled-skills/lore/README.md +386 -0
- package/bundled-skills/lore/README.zh-CN.md +386 -0
- package/bundled-skills/lore/SKILL.md +453 -0
- package/bundled-skills/lore/WORKFLOWS.md +216 -0
- package/bundled-skills/lore/WORKFLOWS.zh-CN.md +216 -0
- package/bundled-skills/lore/references/audit-template.md +60 -0
- package/bundled-skills/lore/references/compatibility.md +228 -0
- package/bundled-skills/lore/references/config.md +125 -0
- package/bundled-skills/lore/references/entry-format.md +70 -0
- package/bundled-skills/lore/references/history-command.md +106 -0
- package/bundled-skills/lore/references/monorepo-detection.md +78 -0
- package/bundled-skills/lore/references/platform-mirrors.md +377 -0
- package/bundled-skills/lore/references/stale-new-markers.md +62 -0
- package/bundled-skills/lore/references/summary-template.md +98 -0
- package/bundled-skills/lore/scripts/README.md +54 -0
- package/bundled-skills/lore/scripts/README.zh-CN.md +54 -0
- package/bundled-skills/lore/scripts/find_duplicates.py +211 -0
- package/bundled-skills/lore/scripts/find_stale.py +116 -0
- package/bundled-skills/lore/scripts/history.py +527 -0
- package/bundled-skills/lore/scripts/id_hash.py +32 -0
- package/bundled-skills/lore/scripts/list_entries.py +183 -0
- package/bundled-skills/lovable-cleanup/SKILL.md +3 -3
- package/bundled-skills/makepad-splash/SKILL.md +1 -1
- package/bundled-skills/mmx-cli/SKILL.md +14 -1
- package/bundled-skills/monopoly/SKILL.md +5 -0
- package/bundled-skills/monopoly/patterns/SKILL.md +4 -0
- package/bundled-skills/monopoly/scale-benchmarks/SKILL.md +4 -0
- package/bundled-skills/monopoly/security-checklist/SKILL.md +4 -0
- package/bundled-skills/monopoly/tech-matrix/SKILL.md +4 -0
- package/bundled-skills/mtls-configuration/SKILL.md +1 -1
- package/bundled-skills/network-101/SKILL.md +4 -5
- package/bundled-skills/nika/SKILL.md +270 -0
- package/bundled-skills/not-a-vibe-coder/SKILL.md +4 -0
- package/bundled-skills/ontoly-software-graph/SKILL.md +160 -0
- package/bundled-skills/openclaw-github-repo-commander/SKILL.md +1 -1
- package/bundled-skills/pilot-protocol/SKILL.md +6 -3
- package/bundled-skills/postgres-readonly-queries/README.md +77 -0
- package/bundled-skills/postgres-readonly-queries/SKILL.md +152 -0
- package/bundled-skills/postgres-readonly-queries/connections.example.json +34 -0
- package/bundled-skills/postgres-readonly-queries/requirements.txt +1 -0
- package/bundled-skills/postgres-readonly-queries/scripts/query.py +262 -0
- package/bundled-skills/pptx-deck-creation/SKILL.md +275 -0
- package/bundled-skills/pptx-deck-creation/references/audit-checklist.md +156 -0
- package/bundled-skills/pptx-deck-creation/references/design-profiles.md +96 -0
- package/bundled-skills/pptx-deck-creation/references/python-snippets.md +150 -0
- package/bundled-skills/pptx-deck-creation/references/reference-deck-analysis.md +91 -0
- package/bundled-skills/pptx-deck-creation/references/visual-asset-adapters.md +158 -0
- package/bundled-skills/privilege-escalation-methods/SKILL.md +1 -1
- package/bundled-skills/product-decision-agent/SKILL.md +94 -0
- package/bundled-skills/product-decision-agent/agents/openai.yaml +7 -0
- package/bundled-skills/product-decision-agent/references/methodology-basis.md +232 -0
- package/bundled-skills/product-decision-agent/references/product-playbooks.md +813 -0
- package/bundled-skills/product-decision-agent/references/reasoning-engine.md +289 -0
- package/bundled-skills/product-decision-agent/references/response-examples.md +279 -0
- package/bundled-skills/product-decision-agent/scripts/quality_gate.py +221 -0
- package/bundled-skills/product-decision-agent/scripts/test_quality_gate.py +94 -0
- package/bundled-skills/pytest-skill/reference/playbook.md +358 -0
- package/bundled-skills/quit-sponsor/SKILL.md +96 -0
- package/bundled-skills/rclone-cli/references/providers/s3.md +1 -1
- package/bundled-skills/security-and-hardening/SKILL.md +1 -1
- package/bundled-skills/semgrep-rule-creator/SKILL.md +6 -6
- package/bundled-skills/skill-creator/README.md +3 -3
- package/bundled-skills/skill-creator/SKILL.md +8 -4
- package/bundled-skills/skill-creator/scripts/quick_validate.py +1 -1
- package/bundled-skills/sql-injection-testing/SKILL.md +4 -4
- package/bundled-skills/subagent-orchestrator/README.md +1 -1
- package/bundled-skills/super-code/bash/SKILL.md +3 -0
- package/bundled-skills/super-code/c/SKILL.md +3 -0
- package/bundled-skills/super-code/cpp/SKILL.md +3 -0
- package/bundled-skills/super-code/csharp/SKILL.md +3 -0
- package/bundled-skills/super-code/dart/SKILL.md +3 -0
- package/bundled-skills/super-code/elixir/SKILL.md +3 -0
- package/bundled-skills/super-code/go/SKILL.md +3 -0
- package/bundled-skills/super-code/java/SKILL.md +3 -0
- package/bundled-skills/super-code/kotlin/SKILL.md +3 -0
- package/bundled-skills/super-code/php/SKILL.md +3 -0
- package/bundled-skills/super-code/python/SKILL.md +3 -0
- package/bundled-skills/super-code/ruby/SKILL.md +3 -0
- package/bundled-skills/super-code/rust/SKILL.md +3 -0
- package/bundled-skills/super-code/scala/SKILL.md +3 -0
- package/bundled-skills/super-code/swift/SKILL.md +3 -0
- package/bundled-skills/super-code/typescript/SKILL.md +3 -0
- package/bundled-skills/telegram-bot-messaging/README.md +185 -0
- package/bundled-skills/telegram-bot-messaging/SKILL.md +101 -0
- package/bundled-skills/telegram-bot-messaging/scripts/telegram.sh +420 -0
- package/bundled-skills/test-guard/SKILL.md +132 -0
- package/bundled-skills/test-guard/references/jest.md +50 -0
- package/bundled-skills/test-guard/references/llm-app-testing.md +40 -0
- package/bundled-skills/test-guard/references/phpunit.md +56 -0
- package/bundled-skills/test-guard/references/pytest.md +65 -0
- package/bundled-skills/trading-ledger/SKILL.md +11 -3
- package/bundled-skills/uizze-ui-research/SKILL.md +93 -0
- package/bundled-skills/vibe-code-auditor/SKILL.md +1 -1
- package/bundled-skills/vibecode-production-qa-validator/SKILL.md +1 -1
- package/bundled-skills/videodb/scripts/ws_listener.py +29 -15
- package/bundled-skills/voice-ai-engine-development/README.md +1 -1
- package/bundled-skills/vulnerability-scanner/SKILL.md +1 -1
- package/bundled-skills/warehouse/SKILL.md +154 -0
- package/bundled-skills/woo-guard/SKILL.md +113 -0
- package/bundled-skills/woo-guard/references/checkout-and-money.md +64 -0
- package/bundled-skills/woo-guard/references/hpos-and-crud.md +87 -0
- package/bundled-skills/woo-guard/references/review-checklist.md +44 -0
- package/bundled-skills/woo-guard/references/sources.md +17 -0
- package/bundled-skills/wp-guard/SKILL.md +119 -0
- package/bundled-skills/wp-guard/references/i18n.md +88 -0
- package/bundled-skills/wp-guard/references/performance.md +70 -0
- package/bundled-skills/wp-guard/references/review-checklist.md +57 -0
- package/bundled-skills/wp-guard/references/security.md +100 -0
- package/bundled-skills/wp-guard/references/sources.md +27 -0
- package/bundled-skills/writing-skills/gotchas.md +1 -1
- package/bundled-skills/writing-skills/references/standards/metadata-standard.md +1 -1
- package/bundled-skills/x-twitter-scraper/SKILL.md +14 -32
- package/bundled-skills/xss-html-injection/SKILL.md +3 -3
- package/bundled-skills/youtube-seo-optimizer/SKILL.md +1 -1
- package/bundled-skills/youtube-summarizer/CHANGELOG.md +2 -2
- package/package.json +1 -1
- package/skills_index.json +273 -0
|
@@ -0,0 +1,1593 @@
|
|
|
1
|
+
# `container` — Complete CLI Command Reference
|
|
2
|
+
|
|
3
|
+
Full command/flag reference for Apple's `container` CLI (repo `apple/container`), invoked as
|
|
4
|
+
`container ...` on Apple-silicon macOS. Flags, defaults, aliases, and behavior are taken from
|
|
5
|
+
the swift-argument-parser declarations in `Sources/ContainerCommands/` (source of truth) and
|
|
6
|
+
`docs/command-reference.md`; on conflicts the source wins.
|
|
7
|
+
|
|
8
|
+
Not Docker. The CLI is deliberately Docker-like, but flags, defaults, and daemon model differ —
|
|
9
|
+
do not assume Docker behavior carries over. Every container runs in its own lightweight VM;
|
|
10
|
+
there is no shared daemon (per-user `launchd` services). Registry lives under the **Image**
|
|
11
|
+
group, not top-level.
|
|
12
|
+
|
|
13
|
+
**Conventions used below:** a value of `—` in the Default column means "no default (unset /
|
|
14
|
+
optional)". "flag" in the Value column means a boolean switch (no argument). `[env: NAME]`
|
|
15
|
+
marks an environment-variable fallback. Command availability varies by macOS version — caveats
|
|
16
|
+
are called out inline.
|
|
17
|
+
|
|
18
|
+
**Version:** this reference tracks the **1.0.0** release. Items marked *(1.0.0+)* were added after
|
|
19
|
+
0.7.1 — namely `container cp`, `container export`, `container prune`, `container image prune`,
|
|
20
|
+
`container registry list`, `container system version`, and the whole `container machine` group (on
|
|
21
|
+
0.7.1 the `registry` group had only `login`/`logout`). Run `container <group> --help` to confirm
|
|
22
|
+
what your installed build supports.
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
26
|
+
## Table of Contents
|
|
27
|
+
|
|
28
|
+
- [Global](#global)
|
|
29
|
+
- [Container lifecycle](#container-lifecycle)
|
|
30
|
+
- [run](#container-run) · [create](#container-create) · [exec](#container-exec) · [start](#container-start) · [stop](#container-stop) · [kill](#container-kill) · [delete / rm](#container-delete-rm) · [list / ls](#container-list-ls) · [logs](#container-logs) · [inspect](#container-inspect) · [stats](#container-stats) · [copy / cp](#container-copy-cp) · [export](#container-export) · [prune](#container-prune)
|
|
31
|
+
- [Images](#images)
|
|
32
|
+
- [build](#container-build) · [image](#container-image-group) · [pull](#container-image-pull) · [push](#container-image-push) · [tag](#container-image-tag) · [save](#container-image-save) · [load](#container-image-load) · [inspect](#container-image-inspect) · [list / ls](#container-image-list-ls) · [delete / rm](#container-image-delete-rm) · [prune](#container-image-prune)
|
|
33
|
+
- [Registry](#registry)
|
|
34
|
+
- [login](#container-registry-login) · [logout](#container-registry-logout) · [list / ls](#container-registry-list-ls)
|
|
35
|
+
- [Builder](#builder)
|
|
36
|
+
- [start](#container-builder-start) · [status](#container-builder-status) · [stop](#container-builder-stop) · [delete / rm](#container-builder-delete-rm)
|
|
37
|
+
- [System](#system)
|
|
38
|
+
- [start](#container-system-start) · [stop](#container-system-stop) · [status](#container-system-status) · [version](#container-system-version) · [logs](#container-system-logs) · [df](#container-system-df) · [dns](#container-system-dns) · [kernel set](#container-system-kernel-set) · [property list](#container-system-property-list-ls)
|
|
39
|
+
- [Network (macOS 26+)](#network-macos-26)
|
|
40
|
+
- [create](#container-network-create) · [delete / rm](#container-network-delete-rm) · [list / ls](#container-network-list-ls) · [inspect](#container-network-inspect) · [prune](#container-network-prune)
|
|
41
|
+
- [Volume](#volume)
|
|
42
|
+
- [create](#container-volume-create) · [delete / rm](#container-volume-delete-rm) · [list / ls](#container-volume-list-ls) · [inspect](#container-volume-inspect) · [prune](#container-volume-prune)
|
|
43
|
+
- [Machine](#machine)
|
|
44
|
+
- [create](#container-machine-create) · [run](#container-machine-run) · [set](#container-machine-set) · [set-default](#container-machine-set-default) · [list / ls](#container-machine-list-ls) · [inspect](#container-machine-inspect) · [logs](#container-machine-logs) · [stop](#container-machine-stop) · [delete / rm](#container-machine-delete-rm)
|
|
45
|
+
|
|
46
|
+
---
|
|
47
|
+
|
|
48
|
+
## Global
|
|
49
|
+
|
|
50
|
+
Root command: `container` — "A container platform for macOS".
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
container [--debug] [--version] [-h|--help] <command> [<args> ...]
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
| Flag | Value | Default | Description |
|
|
57
|
+
|------|-------|---------|-------------|
|
|
58
|
+
| `--debug` | flag | `false` | Enable debug output. Applies to every command (composed via `Flags.Logging`). `[env: CONTAINER_DEBUG]` — setting the env var (any value) also enables debug. |
|
|
59
|
+
| `--version` | flag | — | Print CLI version (`container CLI version …`) and exit. |
|
|
60
|
+
| `-h, --help` | flag | — | Show help. On the bare root command, help is augmented with a `PLUGINS:` section. |
|
|
61
|
+
|
|
62
|
+
Notes:
|
|
63
|
+
- **There is no global `-d` short flag.** `--debug` is long-only. `-d` is `--detach` on `run`/`create`/`exec`/`machine run`.
|
|
64
|
+
- `--debug` is accepted on essentially every subcommand (each command composes `Flags.Logging`), so it is omitted from the per-command tables below unless useful.
|
|
65
|
+
- The CLI refuses to run under Rosetta translation (it exits with an error telling you to disable Rosetta in your terminal). Apple silicon only.
|
|
66
|
+
- Most commands talk to the background API server. If it is not running you get an "XPC connection error" hint: *"Ensure container system service has been started with `container system start`."* Run `container system start` first.
|
|
67
|
+
|
|
68
|
+
### Command groups
|
|
69
|
+
|
|
70
|
+
Top-level help organizes subcommands into groups: **Container** (lifecycle), **Image**
|
|
71
|
+
(`build`, `image`, `registry`), **Machine**, **Volume**, and **Other** (`builder`,
|
|
72
|
+
`network`, `system`). Group aliases:
|
|
73
|
+
|
|
74
|
+
| Group | Alias | Note |
|
|
75
|
+
|-------|-------|------|
|
|
76
|
+
| `container image` | `i` | The plural `images` is only the help section header, not a command (`container images` errors with "plugin not found"). |
|
|
77
|
+
| `container registry` | `r` | Nested under the Image group. |
|
|
78
|
+
| `container machine` | `m` | |
|
|
79
|
+
| `container volume` | `v` | |
|
|
80
|
+
| `container network` | `n` | **macOS 26+ only** (absent on macOS 15). |
|
|
81
|
+
| `container system` | `s` | |
|
|
82
|
+
| `container builder` | (none) | |
|
|
83
|
+
|
|
84
|
+
### Plugin passthrough
|
|
85
|
+
|
|
86
|
+
If the first argument is not a recognized subcommand (and does not start with `-`), the CLI
|
|
87
|
+
treats it as a **plugin invocation**: it looks for an executable named `container-<arg>` and
|
|
88
|
+
`execvp`s into it, passing through all remaining arguments.
|
|
89
|
+
|
|
90
|
+
- Plugin search directories (in order): the user plugins dir under the install root, the app
|
|
91
|
+
bundle's `plugins/`, and `<install-root>/libexec/container/plugins/`. Only plugins whose
|
|
92
|
+
config declares `isCLI` are eligible.
|
|
93
|
+
- Requires the system services to be running (the plugin loader queries the API server). If
|
|
94
|
+
they are not, you get: *"Plugins are unavailable. Start the container system services and
|
|
95
|
+
retry: `container system start`."*
|
|
96
|
+
- If no matching plugin is found: *"Plugin 'container-<arg>' not found."* with the searched
|
|
97
|
+
paths listed.
|
|
98
|
+
- An unknown token starting with `-` yields *"unknown option '…'"*; an empty token yields
|
|
99
|
+
*"unknown argument '…'"*.
|
|
100
|
+
- Before exec, `SIGINT`/`SIGTERM` handlers are reset to default so the plugin manages its own signals.
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
container myplugin --flag arg # execs container-myplugin --flag arg
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
---
|
|
107
|
+
|
|
108
|
+
## Container lifecycle
|
|
109
|
+
|
|
110
|
+
The following flag groups are shared (composed via `@OptionGroup`) across `run`, `create`,
|
|
111
|
+
and — for the process subset — `exec`. They are defined once here and referenced by name.
|
|
112
|
+
|
|
113
|
+
**Process options** (`run`, `create`, `exec`):
|
|
114
|
+
|
|
115
|
+
| Flag | Value | Default | Description |
|
|
116
|
+
|------|-------|---------|-------------|
|
|
117
|
+
| `-e, --env` | `<key=value>` | — | Set env var. `key=value`, or bare `key` to inherit from host. Repeatable. |
|
|
118
|
+
| `--env-file` | `<path>` | — | Read env vars from a file (`key=value`; ignores `#` comments and blank lines). Repeatable. |
|
|
119
|
+
| `--gid` | `<gid>` | — | Group ID for the process. |
|
|
120
|
+
| `-i, --interactive` | flag | `false` | Keep stdin open even if not attached. |
|
|
121
|
+
| `-t, --tty` | flag | `false` | Open a TTY for the process. |
|
|
122
|
+
| `-u, --user` | `<user>` | — | User for the process (format `name` \| `uid[:gid]`). |
|
|
123
|
+
| `--uid` | `<uid>` | — | User ID for the process. |
|
|
124
|
+
| `-w, --workdir, --cwd` | `<dir>` | — | Initial working directory inside the container. (`-w`, `--workdir`, and `--cwd` are all accepted.) |
|
|
125
|
+
| `--ulimit` | `<type>=<soft>[:<hard>]` | — | Resource limit (`RLIMIT_*`, e.g. `nofile=1024:2048`). Repeatable. Part of the shared Process group, so it also parses on `exec`. |
|
|
126
|
+
|
|
127
|
+
**Resource options** (`run`, `create`):
|
|
128
|
+
|
|
129
|
+
| Flag | Value | Default | Description |
|
|
130
|
+
|------|-------|---------|-------------|
|
|
131
|
+
| `-c, --cpus` | `<n>` | — | Number of CPUs to allocate. |
|
|
132
|
+
| `-m, --memory` | `<size>` | — | Memory (1 MiB granularity); optional `K`/`M`/`G`/`T`/`P` suffix. |
|
|
133
|
+
|
|
134
|
+
**Management options** (`run`, `create`):
|
|
135
|
+
|
|
136
|
+
| Flag | Value | Default | Description |
|
|
137
|
+
|------|-------|---------|-------------|
|
|
138
|
+
| `-a, --arch` | `<arch>` | host arch (e.g. `arm64`) | Arch to use if the image is multi-arch. |
|
|
139
|
+
| `--cap-add` | `<cap>` | — | Add a Linux capability (`CAP_NET_RAW`, `NET_RAW`, or `ALL`). Repeatable. |
|
|
140
|
+
| `--cap-drop` | `<cap>` | — | Drop a Linux capability. Repeatable. |
|
|
141
|
+
| `--cidfile` | `<path>` | `""` | Write the container ID to this path. |
|
|
142
|
+
| `-d, --detach` | flag | `false` | Run detached from the process. |
|
|
143
|
+
| `--dns` | `<ip>` | — | DNS nameserver IP. Repeatable. |
|
|
144
|
+
| `--dns-domain` | `<domain>` | — | Default DNS domain. |
|
|
145
|
+
| `--dns-option` | `<option>` | — | DNS option. Repeatable. |
|
|
146
|
+
| `--dns-search` | `<domain>` | — | DNS search domain. Repeatable. |
|
|
147
|
+
| `--entrypoint` | `<cmd>` | — | Override the image entrypoint. |
|
|
148
|
+
| `--init` | flag | `false` | Run an init process that forwards signals and reaps zombies. |
|
|
149
|
+
| `--init-image` | `<image>` | — | Custom init image (customize boot-time behavior: VM daemons, eBPF filters, debugging init). |
|
|
150
|
+
| `-k, --kernel` | `<path>` | — | Custom kernel path (resolved to an absolute path). |
|
|
151
|
+
| `-l, --label` | `<key=value>` | — | Add a label. Repeatable. |
|
|
152
|
+
| `--mount` | `<spec>` | — | Add a mount (`type=<>,source=<>,target=<>,readonly`). Repeatable. |
|
|
153
|
+
| `--name` | `<name>` | — | Use this name as the container ID (auto-generated otherwise). |
|
|
154
|
+
| `--network` | `<spec>` | — | Attach to a network (`<name>[,mac=XX:XX:XX:XX:XX:XX][,mtu=VALUE]`). Repeatable. |
|
|
155
|
+
| `--no-dns` | flag | `false` | Do not configure DNS. Conflicts with any `--dns*` flag (validation error). |
|
|
156
|
+
| `--os` | `<os>` | `linux` | OS to use if the image is multi-OS. |
|
|
157
|
+
| `-p, --publish` | `<spec>` | — | Publish a port (`[host-ip:]host-port:container-port[/protocol]`). Repeatable. |
|
|
158
|
+
| `--platform` | `<platform>` | — | Platform for multi-platform images (`os/arch[/variant]`). Takes precedence over `--os`/`--arch`. `[env: CONTAINER_DEFAULT_PLATFORM]` |
|
|
159
|
+
| `--publish-socket` | `<spec>` | — | Publish a socket (`host_path:container_path`). Repeatable. |
|
|
160
|
+
| `--read-only` | flag | `false` | Mount the root filesystem read-only. |
|
|
161
|
+
| `--rm, --remove` | flag | `false` | Remove the container after it stops. |
|
|
162
|
+
| `--rosetta` | flag | `false` | Enable Rosetta in the container. |
|
|
163
|
+
| `--runtime` | `<handler>` | — | Runtime handler (default: `container-runtime-linux`). |
|
|
164
|
+
| `--ssh` | flag | `false` | Forward the SSH agent socket into the container. |
|
|
165
|
+
| `--shm-size` | `<size>` | — | Size of `/dev/shm` (e.g. `64M`, `1G`). |
|
|
166
|
+
| `--tmpfs` | `<path>` | — | Add a tmpfs mount at the given path. Repeatable. |
|
|
167
|
+
| `-v, --volume` | `<spec>` | — | Bind-mount a volume. Repeatable. |
|
|
168
|
+
| `--virtualization` | flag | `false` | Expose virtualization capabilities (requires host and guest support). |
|
|
169
|
+
|
|
170
|
+
**Registry options** (`run`, `create`):
|
|
171
|
+
|
|
172
|
+
| Flag | Value | Default | Description |
|
|
173
|
+
|------|-------|---------|-------------|
|
|
174
|
+
| `--scheme` | `http\|https\|auto` | `auto` | Scheme for registry connections. `auto` picks `http` for loopback / RFC-1918 / internal-DNS-domain hosts, else `https`. |
|
|
175
|
+
|
|
176
|
+
**Progress options** (`run`, `create`): `--progress <auto\|none\|ansi\|plain\|color>` (default `auto`).
|
|
177
|
+
|
|
178
|
+
**Image-fetch options** (`run`, `create`): `--max-concurrent-downloads <n>` (default `3`).
|
|
179
|
+
|
|
180
|
+
---
|
|
181
|
+
|
|
182
|
+
### `container run`
|
|
183
|
+
|
|
184
|
+
Run a container from an image. If a command is given, it runs inside the container; otherwise
|
|
185
|
+
the image's default command runs. Foreground by default; stdin stays closed unless `-i`.
|
|
186
|
+
|
|
187
|
+
```bash
|
|
188
|
+
container run [<options>] <image> [<arguments> ...]
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
**Arguments:** `<image>` (image name, required) · `<arguments>` (init-process args, captured for passthrough — everything after the image is forwarded verbatim).
|
|
192
|
+
|
|
193
|
+
**Options:** all Process + Resource + Management + Registry + Progress + Image-fetch groups above.
|
|
194
|
+
|
|
195
|
+
```bash
|
|
196
|
+
# interactive shell
|
|
197
|
+
container run -it ubuntu:latest /bin/bash
|
|
198
|
+
# detached web server with a name and a published port
|
|
199
|
+
container run -d --name web -p 8080:80 nginx:latest
|
|
200
|
+
# env + resource limits
|
|
201
|
+
container run -e NODE_ENV=production --cpus 2 --memory 1G node:18
|
|
202
|
+
# fixed MAC on the default network
|
|
203
|
+
container run --network default,mac=02:42:ac:11:00:02 ubuntu:latest
|
|
204
|
+
# reap zombies / forward signals
|
|
205
|
+
container run --init ubuntu:latest my-app
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
Notes: on non-detached, non-TTY runs, pressing Ctrl-C 3× force-exits. `--rm` removes the
|
|
209
|
+
container after it exits. On error the partially-created container is deleted.
|
|
210
|
+
|
|
211
|
+
---
|
|
212
|
+
|
|
213
|
+
### `container create`
|
|
214
|
+
|
|
215
|
+
Create a container from an image **without starting it**. Same Process/Resource/Management/
|
|
216
|
+
Registry/Progress/Image-fetch flags as `run`; the container is left stopped.
|
|
217
|
+
|
|
218
|
+
```bash
|
|
219
|
+
container create [<options>] <image> [<arguments> ...]
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
**Arguments:** `<image>` (required) · `<arguments>` (init-process args, passthrough).
|
|
223
|
+
|
|
224
|
+
**Options:** identical to [`container run`](#container-run).
|
|
225
|
+
|
|
226
|
+
```bash
|
|
227
|
+
container create --name web -p 8080:80 nginx:latest
|
|
228
|
+
container start web
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
---
|
|
232
|
+
|
|
233
|
+
### `container exec`
|
|
234
|
+
|
|
235
|
+
Run a command inside a **running** container. Uses the Process options group.
|
|
236
|
+
|
|
237
|
+
```bash
|
|
238
|
+
container exec [-d] [<process options>] <container-id> <arguments> ...
|
|
239
|
+
```
|
|
240
|
+
|
|
241
|
+
**Arguments:** `<container-id>` (required) · `<arguments>` (new process args, passthrough — first arg is the executable).
|
|
242
|
+
|
|
243
|
+
| Flag | Value | Default | Description |
|
|
244
|
+
|------|-------|---------|-------------|
|
|
245
|
+
| `-d, --detach` | flag | `false` | Run the process and detach from it. |
|
|
246
|
+
|
|
247
|
+
Plus the **full** Process options group (`-e/--env`, `--env-file`, `--gid`, `-i/--interactive`,
|
|
248
|
+
`-t/--tty`, `-u/--user`, `--uid`, `-w/--workdir/--cwd`, `--ulimit`) — `exec` composes the same
|
|
249
|
+
`Flags.Process` group as `run`/`create`, so all of these are accepted on `exec` too.
|
|
250
|
+
|
|
251
|
+
```bash
|
|
252
|
+
container exec -it web /bin/sh
|
|
253
|
+
container exec -e DEBUG=1 -u root web env
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
---
|
|
257
|
+
|
|
258
|
+
### `container start`
|
|
259
|
+
|
|
260
|
+
Start a stopped container. Optionally attach to its output and keep stdin open.
|
|
261
|
+
|
|
262
|
+
```bash
|
|
263
|
+
container start [-a] [-i] <container-id>
|
|
264
|
+
```
|
|
265
|
+
|
|
266
|
+
**Arguments:** `<container-id>` (required).
|
|
267
|
+
|
|
268
|
+
| Flag | Value | Default | Description |
|
|
269
|
+
|------|-------|---------|-------------|
|
|
270
|
+
| `-a, --attach` | flag | `false` | Attach stdout/stderr. |
|
|
271
|
+
| `-i, --interactive` | flag | `false` | Attach stdin. |
|
|
272
|
+
|
|
273
|
+
If neither `-a` nor `-i` is given, the container runs detached.
|
|
274
|
+
|
|
275
|
+
```bash
|
|
276
|
+
container start web
|
|
277
|
+
container start -ai mybox
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
---
|
|
281
|
+
|
|
282
|
+
### `container stop`
|
|
283
|
+
|
|
284
|
+
Gracefully stop running containers by sending a signal, then `SIGKILL` after a timeout.
|
|
285
|
+
|
|
286
|
+
```bash
|
|
287
|
+
container stop [-a] [-s <signal>] [-t <time>] [<container-ids> ...]
|
|
288
|
+
```
|
|
289
|
+
|
|
290
|
+
**Arguments:** `<container-ids>` (zero or more; nothing is stopped without IDs unless `-a`).
|
|
291
|
+
|
|
292
|
+
| Flag | Value | Default | Description |
|
|
293
|
+
|------|-------|---------|-------------|
|
|
294
|
+
| `-a, --all` | flag | `false` | Stop all running containers. |
|
|
295
|
+
| `-s, --signal` | `<signal>` | `SIGTERM` (effective) | Signal to send. The CLI flag itself has no hard default — when omitted the server applies the graceful default (`SIGTERM`). |
|
|
296
|
+
| `-t, --time` | `<seconds>` | `5` | Seconds to wait before `SIGKILL`. |
|
|
297
|
+
|
|
298
|
+
Aliases: none.
|
|
299
|
+
|
|
300
|
+
```bash
|
|
301
|
+
container stop web
|
|
302
|
+
container stop -a
|
|
303
|
+
container stop -s SIGINT -t 10 web db
|
|
304
|
+
```
|
|
305
|
+
|
|
306
|
+
---
|
|
307
|
+
|
|
308
|
+
### `container kill`
|
|
309
|
+
|
|
310
|
+
Immediately signal (default `KILL`) running containers. No graceful shutdown — use with care.
|
|
311
|
+
|
|
312
|
+
```bash
|
|
313
|
+
container kill [-a] [-s <signal>] [<container-ids> ...]
|
|
314
|
+
```
|
|
315
|
+
|
|
316
|
+
**Arguments:** `<container-ids>` (zero or more; nothing killed without IDs unless `-a`).
|
|
317
|
+
|
|
318
|
+
| Flag | Value | Default | Description |
|
|
319
|
+
|------|-------|---------|-------------|
|
|
320
|
+
| `-a, --all` | flag | `false` | Kill/signal all running containers. |
|
|
321
|
+
| `-s, --signal` | `<signal>` | `KILL` | Signal to send. |
|
|
322
|
+
|
|
323
|
+
```bash
|
|
324
|
+
container kill web
|
|
325
|
+
container kill -s HUP -a
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
---
|
|
329
|
+
|
|
330
|
+
### `container delete (rm)`
|
|
331
|
+
|
|
332
|
+
Delete one or more containers. Running containers require `--force`.
|
|
333
|
+
|
|
334
|
+
```bash
|
|
335
|
+
container delete [-a] [-f] [<container-ids> ...]
|
|
336
|
+
container rm [-a] [-f] [<container-ids> ...]
|
|
337
|
+
```
|
|
338
|
+
|
|
339
|
+
**Aliases:** `rm`. **Arguments:** `<container-ids>` (zero or more; nothing deleted without IDs unless `-a`).
|
|
340
|
+
|
|
341
|
+
| Flag | Value | Default | Description |
|
|
342
|
+
|------|-------|---------|-------------|
|
|
343
|
+
| `-a, --all` | flag | `false` | Delete all containers. |
|
|
344
|
+
| `-f, --force` | flag | `false` | Delete even if running. |
|
|
345
|
+
|
|
346
|
+
```bash
|
|
347
|
+
container delete web
|
|
348
|
+
container rm -f web
|
|
349
|
+
container rm --all
|
|
350
|
+
```
|
|
351
|
+
|
|
352
|
+
---
|
|
353
|
+
|
|
354
|
+
### `container list (ls)`
|
|
355
|
+
|
|
356
|
+
List containers. By default only running ones are shown.
|
|
357
|
+
|
|
358
|
+
```bash
|
|
359
|
+
container list [-a] [--format <format>] [-q]
|
|
360
|
+
container ls [-a] [--format <format>] [-q]
|
|
361
|
+
```
|
|
362
|
+
|
|
363
|
+
**Aliases:** `ls`.
|
|
364
|
+
|
|
365
|
+
| Flag | Value | Default | Description |
|
|
366
|
+
|------|-------|---------|-------------|
|
|
367
|
+
| `-a, --all` | flag | `false` | Include non-running containers. |
|
|
368
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
369
|
+
| `-q, --quiet` | flag | `false` | Only output the container ID. |
|
|
370
|
+
|
|
371
|
+
```bash
|
|
372
|
+
container ls
|
|
373
|
+
container ls -a --format json
|
|
374
|
+
container ls -q
|
|
375
|
+
```
|
|
376
|
+
|
|
377
|
+
---
|
|
378
|
+
|
|
379
|
+
### `container logs`
|
|
380
|
+
|
|
381
|
+
Fetch a container's logs. Follow, tail, or view the boot log.
|
|
382
|
+
|
|
383
|
+
```bash
|
|
384
|
+
container logs [--boot] [-f] [-n <n>] <container-id>
|
|
385
|
+
```
|
|
386
|
+
|
|
387
|
+
**Arguments:** `<container-id>` (required).
|
|
388
|
+
|
|
389
|
+
| Flag | Value | Default | Description |
|
|
390
|
+
|------|-------|---------|-------------|
|
|
391
|
+
| `--boot` | flag | `false` | Show the boot log instead of stdio. |
|
|
392
|
+
| `-f, --follow` | flag | `false` | Follow log output. |
|
|
393
|
+
| `-n` | `<n>` | — (all) | Show the last `n` lines. `-n` is short-only (no `--lines`). Omit to print everything. |
|
|
394
|
+
|
|
395
|
+
```bash
|
|
396
|
+
container logs -f web
|
|
397
|
+
container logs -n 100 web
|
|
398
|
+
container logs --boot web
|
|
399
|
+
```
|
|
400
|
+
|
|
401
|
+
---
|
|
402
|
+
|
|
403
|
+
### `container inspect`
|
|
404
|
+
|
|
405
|
+
Print detailed container info as pretty JSON.
|
|
406
|
+
|
|
407
|
+
```bash
|
|
408
|
+
container inspect <container-ids> ...
|
|
409
|
+
```
|
|
410
|
+
|
|
411
|
+
**Arguments:** `<container-ids>` (one or more, required). Duplicates de-duplicated; a missing ID errors.
|
|
412
|
+
|
|
413
|
+
No options beyond global.
|
|
414
|
+
|
|
415
|
+
```bash
|
|
416
|
+
container inspect web
|
|
417
|
+
container inspect web db
|
|
418
|
+
```
|
|
419
|
+
|
|
420
|
+
---
|
|
421
|
+
|
|
422
|
+
### `container stats`
|
|
423
|
+
|
|
424
|
+
Real-time resource usage (CPU %, memory, net I/O, block I/O, PIDs). Interactive by default
|
|
425
|
+
(like `top`); `--no-stream` gives one snapshot.
|
|
426
|
+
|
|
427
|
+
```bash
|
|
428
|
+
container stats [--format <format>] [--no-stream] [<container-ids> ...]
|
|
429
|
+
```
|
|
430
|
+
|
|
431
|
+
**Arguments:** `<container-ids>` (optional; all running containers if omitted).
|
|
432
|
+
|
|
433
|
+
| Flag | Value | Default | Description |
|
|
434
|
+
|------|-------|---------|-------------|
|
|
435
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. Any non-`table` format implies a single snapshot. |
|
|
436
|
+
| `--no-stream` | flag | `false` | Single snapshot instead of streaming. |
|
|
437
|
+
|
|
438
|
+
```bash
|
|
439
|
+
container stats
|
|
440
|
+
container stats web db cache
|
|
441
|
+
container stats --no-stream web
|
|
442
|
+
container stats --format json --no-stream web
|
|
443
|
+
```
|
|
444
|
+
|
|
445
|
+
---
|
|
446
|
+
|
|
447
|
+
### `container copy (cp)`
|
|
448
|
+
|
|
449
|
+
> **⚠️ Requires 1.0.0+** (added after 0.7.1).
|
|
450
|
+
|
|
451
|
+
Copy files between a **running** container and the host. Exactly one side must be a container
|
|
452
|
+
reference `container_id:path`.
|
|
453
|
+
|
|
454
|
+
```bash
|
|
455
|
+
container copy <source> <destination>
|
|
456
|
+
container cp <source> <destination>
|
|
457
|
+
```
|
|
458
|
+
|
|
459
|
+
**Aliases:** `cp`. **Arguments:** `<source>`, `<destination>` (each a local path or `container_id:path`).
|
|
460
|
+
|
|
461
|
+
No options beyond global.
|
|
462
|
+
|
|
463
|
+
```bash
|
|
464
|
+
container cp ./config.json web:/etc/app/
|
|
465
|
+
container cp web:/var/log/app.log ./logs/
|
|
466
|
+
```
|
|
467
|
+
|
|
468
|
+
---
|
|
469
|
+
|
|
470
|
+
### `container export`
|
|
471
|
+
|
|
472
|
+
> **⚠️ Requires 1.0.0+** (added after 0.7.1). The container **must be stopped** first, or it errors
|
|
473
|
+
> `invalidState: "container is not stopped"`.
|
|
474
|
+
|
|
475
|
+
Export a **stopped** container's filesystem as a tar archive. Streams to stdout if `-o` omitted.
|
|
476
|
+
|
|
477
|
+
```bash
|
|
478
|
+
container export [-o <output>] <container-id>
|
|
479
|
+
```
|
|
480
|
+
|
|
481
|
+
**Arguments:** `<container-id>` (required).
|
|
482
|
+
|
|
483
|
+
| Flag | Value | Default | Description |
|
|
484
|
+
|------|-------|---------|-------------|
|
|
485
|
+
| `-o, --output` | `<path>` | stdout | Pathname for the saved filesystem tar. |
|
|
486
|
+
|
|
487
|
+
```bash
|
|
488
|
+
container stop mybox
|
|
489
|
+
container export -o mybox.tar mybox
|
|
490
|
+
container export mybox > mybox.tar
|
|
491
|
+
```
|
|
492
|
+
|
|
493
|
+
---
|
|
494
|
+
|
|
495
|
+
### `container prune`
|
|
496
|
+
|
|
497
|
+
> **⚠️ Requires 1.0.0+** (added after 0.7.1). Removes all *stopped* containers — distinct from
|
|
498
|
+
> `container image prune` / `container volume prune`.
|
|
499
|
+
|
|
500
|
+
Remove **stopped** containers to reclaim disk space; prints the space freed.
|
|
501
|
+
|
|
502
|
+
```bash
|
|
503
|
+
container prune
|
|
504
|
+
```
|
|
505
|
+
|
|
506
|
+
No arguments, no options beyond global.
|
|
507
|
+
|
|
508
|
+
---
|
|
509
|
+
|
|
510
|
+
## Images
|
|
511
|
+
|
|
512
|
+
### `container build`
|
|
513
|
+
|
|
514
|
+
Build an OCI image from a local context using BuildKit (in an isolated builder container).
|
|
515
|
+
When `-f` is not given, looks for `Dockerfile`, then falls back to `Containerfile`.
|
|
516
|
+
|
|
517
|
+
```bash
|
|
518
|
+
container build [<options>] [<context-dir>]
|
|
519
|
+
```
|
|
520
|
+
|
|
521
|
+
**Arguments:** `<context-dir>` (default `.`).
|
|
522
|
+
|
|
523
|
+
| Flag | Value | Default | Description |
|
|
524
|
+
|------|-------|---------|-------------|
|
|
525
|
+
| `-a, --arch` | `<value>` | host arch (e.g. `arm64`) | Add an architecture to the build (comma-separated and/or repeatable). |
|
|
526
|
+
| `--build-arg` | `<key=val>` | — | Build-time variable. Repeatable. |
|
|
527
|
+
| `--cache-in` | `<value>` | — | (Hidden/advanced) BuildKit cache import. Repeatable. |
|
|
528
|
+
| `--cache-out` | `<value>` | — | (Hidden/advanced) BuildKit cache export. Repeatable. |
|
|
529
|
+
| `-c, --cpus` | `<n>` | `2` | CPUs for the builder container. |
|
|
530
|
+
| `--dns` | `<ip>` | — | DNS nameserver IP for the build. Repeatable. |
|
|
531
|
+
| `--dns-domain` | `<domain>` | — | Default DNS domain. |
|
|
532
|
+
| `--dns-option` | `<option>` | — | DNS option. Repeatable. |
|
|
533
|
+
| `--dns-search` | `<domain>` | — | DNS search domain. Repeatable. |
|
|
534
|
+
| `-f, --file` | `<path>` | `Dockerfile`→`Containerfile` | Path to the Dockerfile/Containerfile. |
|
|
535
|
+
| `-l, --label` | `<key=val>` | — | Set a label. Repeatable. |
|
|
536
|
+
| `-m, --memory` | `<size>` | `2048MB` | Builder container memory; optional `K`/`M`/`G`/`T`/`P` suffix. |
|
|
537
|
+
| `--no-cache` | flag | `false` | Do not use the build cache. |
|
|
538
|
+
| `-o, --output` | `<value>` | `type=oci` | Output config (`type=<oci\|tar\|local>[,dest=]`). |
|
|
539
|
+
| `--os` | `<value>` | `linux` | Add an OS to the build (comma-separated and/or repeatable). |
|
|
540
|
+
| `--platform` | `<platform>` | — | Add a platform (`os/arch[/variant]`); precedence over `--os`/`--arch`. `[env: CONTAINER_DEFAULT_PLATFORM]` |
|
|
541
|
+
| `--progress` | `auto\|plain\|tty` | `auto` | Build progress type. (Note the values differ from the pull/push progress set.) |
|
|
542
|
+
| `--pull` | flag | `false` | Pull the latest base image. |
|
|
543
|
+
| `-q, --quiet` | flag | `false` | Suppress build output. |
|
|
544
|
+
| `--secret` | `id=<key>,...` | — | Build secret (`id=<key>[,env=<ENV_VAR>\|,src=<local/path>]`). Repeatable. |
|
|
545
|
+
| `-t, --tag` | `<name>` | — | Name/tag for the built image. Repeatable. |
|
|
546
|
+
| `--target` | `<stage>` | `""` | Target build stage. |
|
|
547
|
+
| `--vsock-port` | `<port>` | `8088` | Builder shim vsock port. |
|
|
548
|
+
|
|
549
|
+
```bash
|
|
550
|
+
container build -t my-app:latest .
|
|
551
|
+
container build -f docker/Dockerfile.prod -t my-app:prod .
|
|
552
|
+
container build --build-arg NODE_VERSION=18 -t my-app .
|
|
553
|
+
container build --target production --no-cache -t my-app:prod .
|
|
554
|
+
container build -t my-app:latest -t my-app:v1.0.0 .
|
|
555
|
+
```
|
|
556
|
+
|
|
557
|
+
---
|
|
558
|
+
|
|
559
|
+
### `container image` group
|
|
560
|
+
|
|
561
|
+
Manage images. **Alias:** `i`. (The plural `images` is only the help section header, not a
|
|
562
|
+
command — `container images` errors with "plugin not found".)
|
|
563
|
+
|
|
564
|
+
```bash
|
|
565
|
+
container image <subcommand>
|
|
566
|
+
container i <subcommand>
|
|
567
|
+
```
|
|
568
|
+
|
|
569
|
+
Subcommands: `pull`, `push`, `tag`, `save`, `load`, `inspect`, `list`/`ls`, `delete`/`rm`, `prune`.
|
|
570
|
+
|
|
571
|
+
---
|
|
572
|
+
|
|
573
|
+
### `container image pull`
|
|
574
|
+
|
|
575
|
+
Pull an image from a registry.
|
|
576
|
+
|
|
577
|
+
```bash
|
|
578
|
+
container image pull [--scheme <scheme>] [--progress <type>] [--max-concurrent-downloads <n>] [-a <arch>] [--os <os>] [--platform <platform>] <reference>
|
|
579
|
+
```
|
|
580
|
+
|
|
581
|
+
**Arguments:** `<reference>` (required).
|
|
582
|
+
|
|
583
|
+
| Flag | Value | Default | Description |
|
|
584
|
+
|------|-------|---------|-------------|
|
|
585
|
+
| `-a, --arch` | `<arch>` | — | Limit to the specified architecture. |
|
|
586
|
+
| `--os` | `<os>` | — | Limit to the specified OS. |
|
|
587
|
+
| `--platform` | `<platform>` | — | Limit to platform (`os/arch[/variant]`); precedence over `--os`/`--arch`. `[env: CONTAINER_DEFAULT_PLATFORM]` |
|
|
588
|
+
| `--scheme` | `http\|https\|auto` | `auto` | Registry connection scheme. |
|
|
589
|
+
| `--progress` | `auto\|none\|ansi\|plain\|color` | `auto` | Progress type. |
|
|
590
|
+
| `--max-concurrent-downloads` | `<n>` | `3` | Max concurrent blob downloads. |
|
|
591
|
+
|
|
592
|
+
```bash
|
|
593
|
+
container image pull docker.io/library/alpine:latest
|
|
594
|
+
container image pull --platform linux/arm64 ubuntu:24.04
|
|
595
|
+
container image pull --scheme http --max-concurrent-downloads 6 registry.local:5000/myapp:dev
|
|
596
|
+
```
|
|
597
|
+
|
|
598
|
+
---
|
|
599
|
+
|
|
600
|
+
### `container image push`
|
|
601
|
+
|
|
602
|
+
Push an image to a registry. Same as `pull` **minus** `--max-concurrent-downloads`.
|
|
603
|
+
|
|
604
|
+
```bash
|
|
605
|
+
container image push [--scheme <scheme>] [--progress <type>] [-a <arch>] [--os <os>] [--platform <platform>] <reference>
|
|
606
|
+
```
|
|
607
|
+
|
|
608
|
+
**Arguments:** `<reference>` (required).
|
|
609
|
+
|
|
610
|
+
| Flag | Value | Default | Description |
|
|
611
|
+
|------|-------|---------|-------------|
|
|
612
|
+
| `-a, --arch` | `<arch>` | — | Limit to architecture. |
|
|
613
|
+
| `--os` | `<os>` | — | Limit to OS. |
|
|
614
|
+
| `--platform` | `<platform>` | — | Limit to platform; precedence over `--os`/`--arch`. `[env: CONTAINER_DEFAULT_PLATFORM]` |
|
|
615
|
+
| `--scheme` | `http\|https\|auto` | `auto` | Registry connection scheme. |
|
|
616
|
+
| `--progress` | `auto\|none\|ansi\|plain\|color` | `auto` | Progress type. |
|
|
617
|
+
|
|
618
|
+
On success the final image reference is printed to stdout.
|
|
619
|
+
|
|
620
|
+
```bash
|
|
621
|
+
container image push registry.local:5000/myapp:1.0.0
|
|
622
|
+
container image push --platform linux/amd64 docker.io/me/tool:latest
|
|
623
|
+
```
|
|
624
|
+
|
|
625
|
+
---
|
|
626
|
+
|
|
627
|
+
### `container image tag`
|
|
628
|
+
|
|
629
|
+
Add a new reference to an existing image. Original reference is unchanged.
|
|
630
|
+
|
|
631
|
+
```bash
|
|
632
|
+
container image tag <source> <target>
|
|
633
|
+
```
|
|
634
|
+
|
|
635
|
+
**Arguments:** `<source>` (`image-name[:tag]`), `<target>` (new reference). No options beyond global. On success the normalized target is printed.
|
|
636
|
+
|
|
637
|
+
```bash
|
|
638
|
+
container image tag alpine:latest myregistry.local/alpine:pinned
|
|
639
|
+
container image tag ubuntu:24.04 ubuntu:lts
|
|
640
|
+
```
|
|
641
|
+
|
|
642
|
+
---
|
|
643
|
+
|
|
644
|
+
### `container image save`
|
|
645
|
+
|
|
646
|
+
Save one or more images as an OCI-compatible tar archive. Streams to **stdout** if `-o` omitted.
|
|
647
|
+
|
|
648
|
+
```bash
|
|
649
|
+
container image save [-a <arch>] [--os <os>] [-o <output>] [--platform <platform>] <references> ...
|
|
650
|
+
```
|
|
651
|
+
|
|
652
|
+
**Arguments:** `<references>` (one or more, required).
|
|
653
|
+
|
|
654
|
+
| Flag | Value | Default | Description |
|
|
655
|
+
|------|-------|---------|-------------|
|
|
656
|
+
| `-a, --arch` | `<arch>` | — | Architecture for the saved image. |
|
|
657
|
+
| `--os` | `<os>` | — | OS for the saved image. |
|
|
658
|
+
| `-o, --output` | `<path>` | stdout | Pathname for the saved tar (resolved to absolute). |
|
|
659
|
+
| `--platform` | `<platform>` | — | Platform (`os/arch[/variant]`); precedence over `--os`/`--arch`. `[env: CONTAINER_DEFAULT_PLATFORM]` |
|
|
660
|
+
|
|
661
|
+
Every reference must resolve; if a platform is resolved, each image must contain content for it
|
|
662
|
+
(else it errors listing available platforms). Without `-o`, the tar goes to stdout and the saved
|
|
663
|
+
reference list is written to stderr (so it doesn't corrupt the stream).
|
|
664
|
+
|
|
665
|
+
```bash
|
|
666
|
+
container image save -o images.tar alpine:latest ubuntu:24.04
|
|
667
|
+
container image save --platform linux/arm64 -o app-arm64.tar myapp:1.0
|
|
668
|
+
container image save alpine:latest > alpine.tar
|
|
669
|
+
```
|
|
670
|
+
|
|
671
|
+
---
|
|
672
|
+
|
|
673
|
+
### `container image load`
|
|
674
|
+
|
|
675
|
+
Load images from an OCI tar archive. Reads **stdin** if `-i` omitted.
|
|
676
|
+
|
|
677
|
+
```bash
|
|
678
|
+
container image load [-i <input>] [-f]
|
|
679
|
+
```
|
|
680
|
+
|
|
681
|
+
No positional arguments.
|
|
682
|
+
|
|
683
|
+
| Flag | Value | Default | Description |
|
|
684
|
+
|------|-------|---------|-------------|
|
|
685
|
+
| `-i, --input` | `<path>` | stdin | Path to the tar archive (resolved to absolute). |
|
|
686
|
+
| `-f, --force` | flag | `false` | Load even if the archive contains invalid member files. |
|
|
687
|
+
|
|
688
|
+
If `--input` names a missing file, the command logs an error and exits `1`. Loaded references
|
|
689
|
+
are printed to stdout; rejected members are warned.
|
|
690
|
+
|
|
691
|
+
```bash
|
|
692
|
+
container image load -i images.tar
|
|
693
|
+
container image load --force --input suspect-archive.tar
|
|
694
|
+
cat alpine.tar | container image load
|
|
695
|
+
```
|
|
696
|
+
|
|
697
|
+
---
|
|
698
|
+
|
|
699
|
+
### `container image inspect`
|
|
700
|
+
|
|
701
|
+
Print detailed image info as pretty JSON.
|
|
702
|
+
|
|
703
|
+
```bash
|
|
704
|
+
container image inspect <images> ...
|
|
705
|
+
```
|
|
706
|
+
|
|
707
|
+
**Arguments:** `<images>` (one or more, required). Duplicates de-duplicated; a missing image
|
|
708
|
+
errors. Infra images (builder / vminit) are filtered out. No options beyond global.
|
|
709
|
+
|
|
710
|
+
```bash
|
|
711
|
+
container image inspect alpine:latest
|
|
712
|
+
container image inspect alpine:latest ubuntu:24.04
|
|
713
|
+
```
|
|
714
|
+
|
|
715
|
+
---
|
|
716
|
+
|
|
717
|
+
### `container image list (ls)`
|
|
718
|
+
|
|
719
|
+
List local images. **Alias:** `ls`.
|
|
720
|
+
|
|
721
|
+
```bash
|
|
722
|
+
container image list [--format <format>] [-q] [-v]
|
|
723
|
+
container image ls [--format <format>] [-q] [-v]
|
|
724
|
+
```
|
|
725
|
+
|
|
726
|
+
| Flag | Value | Default | Description |
|
|
727
|
+
|------|-------|---------|-------------|
|
|
728
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
729
|
+
| `-q, --quiet` | flag | `false` | Only output the image name. |
|
|
730
|
+
| `-v, --verbose` | flag | `false` | Verbose (one row per platform variant). |
|
|
731
|
+
|
|
732
|
+
`-q` and `-v` are mutually exclusive (error if both). Infra images are always hidden; results
|
|
733
|
+
sorted by reference. Verbose columns: `NAME`, `TAG`, `INDEX DIGEST`, `OS`, `ARCH`, `VARIANT`,
|
|
734
|
+
`FULL SIZE`, `CREATED`, `MANIFEST DIGEST`.
|
|
735
|
+
|
|
736
|
+
```bash
|
|
737
|
+
container image list
|
|
738
|
+
container image ls --format json
|
|
739
|
+
container image ls -q
|
|
740
|
+
container image list --verbose
|
|
741
|
+
```
|
|
742
|
+
|
|
743
|
+
---
|
|
744
|
+
|
|
745
|
+
### `container image delete (rm)`
|
|
746
|
+
|
|
747
|
+
Delete one or more images. **Alias:** `rm`.
|
|
748
|
+
|
|
749
|
+
```bash
|
|
750
|
+
container image delete [-a] [-f] [<images> ...]
|
|
751
|
+
container image rm [-a] [-f] [<images> ...]
|
|
752
|
+
```
|
|
753
|
+
|
|
754
|
+
**Arguments:** `<images>` (zero or more).
|
|
755
|
+
|
|
756
|
+
| Flag | Value | Default | Description |
|
|
757
|
+
|------|-------|---------|-------------|
|
|
758
|
+
| `-a, --all` | flag | `false` | Delete all images. |
|
|
759
|
+
| `-f, --force` | flag | `false` | Ignore "not found" errors. |
|
|
760
|
+
|
|
761
|
+
Exactly one of explicit images **or** `--all` must be supplied (supplying both, or neither,
|
|
762
|
+
errors). Infra images skipped; orphaned blobs are GC'd afterward and reclaimed space is logged.
|
|
763
|
+
|
|
764
|
+
```bash
|
|
765
|
+
container image delete alpine:latest
|
|
766
|
+
container image rm --all
|
|
767
|
+
container image delete --force ghost:missing alpine:latest
|
|
768
|
+
```
|
|
769
|
+
|
|
770
|
+
---
|
|
771
|
+
|
|
772
|
+
### `container image prune`
|
|
773
|
+
|
|
774
|
+
> **⚠️ Requires 1.0.0+** (added after 0.7.1).
|
|
775
|
+
|
|
776
|
+
Remove unused images to reclaim space. Default removes only **dangling** (untagged) images;
|
|
777
|
+
`-a` removes every image not referenced by any container.
|
|
778
|
+
|
|
779
|
+
```bash
|
|
780
|
+
container image prune [-a]
|
|
781
|
+
```
|
|
782
|
+
|
|
783
|
+
| Flag | Value | Default | Description |
|
|
784
|
+
|------|-------|---------|-------------|
|
|
785
|
+
| `-a, --all` | flag | `false` | Remove all unused images, not just dangling ones. |
|
|
786
|
+
|
|
787
|
+
```bash
|
|
788
|
+
container image prune
|
|
789
|
+
container image prune --all
|
|
790
|
+
```
|
|
791
|
+
|
|
792
|
+
---
|
|
793
|
+
|
|
794
|
+
## Registry
|
|
795
|
+
|
|
796
|
+
Manage registry logins. **Group alias:** `r`. Nested under the Image group. Credentials are
|
|
797
|
+
stored in the macOS keychain.
|
|
798
|
+
|
|
799
|
+
> Note: source declares only `login`, `logout`, and `list`. There is **no** `registry default`
|
|
800
|
+
> get/set command in the current source (despite occasional mentions of "default registry"
|
|
801
|
+
> elsewhere — that concept lives in system configuration, not this group).
|
|
802
|
+
|
|
803
|
+
```bash
|
|
804
|
+
container registry <subcommand>
|
|
805
|
+
container r <subcommand>
|
|
806
|
+
```
|
|
807
|
+
|
|
808
|
+
---
|
|
809
|
+
|
|
810
|
+
### `container registry login`
|
|
811
|
+
|
|
812
|
+
Authenticate with a registry; credentials are saved to the keychain for reuse.
|
|
813
|
+
|
|
814
|
+
```bash
|
|
815
|
+
container registry login [--scheme <scheme>] [--password-stdin] [-u <username>] <server>
|
|
816
|
+
```
|
|
817
|
+
|
|
818
|
+
**Arguments:** `<server>` (registry server name, required).
|
|
819
|
+
|
|
820
|
+
| Flag | Value | Default | Description |
|
|
821
|
+
|------|-------|---------|-------------|
|
|
822
|
+
| `--scheme` | `http\|https\|auto` | `auto` | Registry connection scheme. |
|
|
823
|
+
| `--password-stdin` | flag | `false` | Read the password from stdin. **Requires `--username`.** |
|
|
824
|
+
| `-u, --username` | `<username>` | `""` | Registry username. |
|
|
825
|
+
|
|
826
|
+
Behavior: `--password-stdin` without `--username` errors (*"must provide --username with
|
|
827
|
+
--password-stdin"*). With no username supplied, prompts interactively for username; with no
|
|
828
|
+
password, prompts interactively. On success it pings the registry (retrying on 5xx) and stores
|
|
829
|
+
the credentials, logging *"Login succeeded"*.
|
|
830
|
+
|
|
831
|
+
```bash
|
|
832
|
+
container registry login registry.example.com # prompts for user + password
|
|
833
|
+
container registry login -u alice ghcr.io # prompts for password only
|
|
834
|
+
echo "$TOKEN" | container registry login -u alice --password-stdin ghcr.io
|
|
835
|
+
container registry login --scheme http localhost:5000
|
|
836
|
+
```
|
|
837
|
+
|
|
838
|
+
---
|
|
839
|
+
|
|
840
|
+
### `container registry logout`
|
|
841
|
+
|
|
842
|
+
Log out, removing stored credentials for the registry.
|
|
843
|
+
|
|
844
|
+
```bash
|
|
845
|
+
container registry logout <registry>
|
|
846
|
+
```
|
|
847
|
+
|
|
848
|
+
**Arguments:** `<registry>` (required). No options beyond global.
|
|
849
|
+
|
|
850
|
+
```bash
|
|
851
|
+
container registry logout ghcr.io
|
|
852
|
+
container r logout registry.example.com
|
|
853
|
+
```
|
|
854
|
+
|
|
855
|
+
---
|
|
856
|
+
|
|
857
|
+
### `container registry list (ls)`
|
|
858
|
+
|
|
859
|
+
> **⚠️ Requires 1.0.0+** (added after 0.7.1). On 0.7.1 the `registry` group had only
|
|
860
|
+
> `login`/`logout`.
|
|
861
|
+
|
|
862
|
+
List saved registry logins. **Alias:** `ls`.
|
|
863
|
+
|
|
864
|
+
```bash
|
|
865
|
+
container registry list [--format <format>] [-q]
|
|
866
|
+
container r ls [--format <format>] [-q]
|
|
867
|
+
```
|
|
868
|
+
|
|
869
|
+
| Flag | Value | Default | Description |
|
|
870
|
+
|------|-------|---------|-------------|
|
|
871
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
872
|
+
| `-q, --quiet` | flag | `false` | Only output the registry hostname. |
|
|
873
|
+
|
|
874
|
+
Table columns: `HOSTNAME`, `USERNAME`, `MODIFIED`, `CREATED` (ISO-8601 dates).
|
|
875
|
+
|
|
876
|
+
```bash
|
|
877
|
+
container registry list
|
|
878
|
+
container registry list --format json
|
|
879
|
+
container registry ls -q
|
|
880
|
+
```
|
|
881
|
+
|
|
882
|
+
---
|
|
883
|
+
|
|
884
|
+
## Builder
|
|
885
|
+
|
|
886
|
+
Manage the BuildKit-based builder container used by `container build`. **No group alias.**
|
|
887
|
+
|
|
888
|
+
```bash
|
|
889
|
+
container builder <subcommand>
|
|
890
|
+
```
|
|
891
|
+
|
|
892
|
+
Subcommands: `start`, `status`, `stop`, `delete`/`rm`.
|
|
893
|
+
|
|
894
|
+
---
|
|
895
|
+
|
|
896
|
+
### `container builder start`
|
|
897
|
+
|
|
898
|
+
Start the BuildKit builder container.
|
|
899
|
+
|
|
900
|
+
```bash
|
|
901
|
+
container builder start [-c <cpus>] [-m <memory>] [--dns <ip> ...] [--dns-domain <domain>] [--dns-option <option> ...] [--dns-search <domain> ...]
|
|
902
|
+
```
|
|
903
|
+
|
|
904
|
+
| Flag | Value | Default | Description |
|
|
905
|
+
|------|-------|---------|-------------|
|
|
906
|
+
| `-c, --cpus` | `<n>` | `2` | CPUs for the builder container. |
|
|
907
|
+
| `-m, --memory` | `<size>` | `2048MB` | Builder memory; optional `K`/`M`/`G`/`T`/`P` suffix. |
|
|
908
|
+
| `--dns` | `<ip>` | — | DNS nameserver IP. Repeatable. |
|
|
909
|
+
| `--dns-domain` | `<domain>` | — | Default DNS domain. |
|
|
910
|
+
| `--dns-option` | `<option>` | — | DNS option. Repeatable. |
|
|
911
|
+
| `--dns-search` | `<domain>` | — | DNS search domain. Repeatable. |
|
|
912
|
+
|
|
913
|
+
```bash
|
|
914
|
+
container builder start
|
|
915
|
+
container builder start -c 4 -m 4G
|
|
916
|
+
```
|
|
917
|
+
|
|
918
|
+
---
|
|
919
|
+
|
|
920
|
+
### `container builder status`
|
|
921
|
+
|
|
922
|
+
Show the builder's status.
|
|
923
|
+
|
|
924
|
+
```bash
|
|
925
|
+
container builder status [--format <format>] [-q]
|
|
926
|
+
```
|
|
927
|
+
|
|
928
|
+
| Flag | Value | Default | Description |
|
|
929
|
+
|------|-------|---------|-------------|
|
|
930
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
931
|
+
| `-q, --quiet` | flag | `false` | Only output the container ID. |
|
|
932
|
+
|
|
933
|
+
When the builder is not running, table output prints `builder is not running` (or empty with `-q`).
|
|
934
|
+
|
|
935
|
+
---
|
|
936
|
+
|
|
937
|
+
### `container builder stop`
|
|
938
|
+
|
|
939
|
+
Stop the builder container.
|
|
940
|
+
|
|
941
|
+
```bash
|
|
942
|
+
container builder stop
|
|
943
|
+
```
|
|
944
|
+
|
|
945
|
+
No arguments, no options beyond global.
|
|
946
|
+
|
|
947
|
+
---
|
|
948
|
+
|
|
949
|
+
### `container builder delete (rm)`
|
|
950
|
+
|
|
951
|
+
Delete the builder container. **Alias:** `rm`.
|
|
952
|
+
|
|
953
|
+
```bash
|
|
954
|
+
container builder delete [-f]
|
|
955
|
+
container builder rm [-f]
|
|
956
|
+
```
|
|
957
|
+
|
|
958
|
+
| Flag | Value | Default | Description |
|
|
959
|
+
|------|-------|---------|-------------|
|
|
960
|
+
| `-f, --force` | flag | `false` | Delete even if the builder is running (else it errors: *"BuildKit container is not stopped, use --force to override"*). |
|
|
961
|
+
|
|
962
|
+
---
|
|
963
|
+
|
|
964
|
+
## System
|
|
965
|
+
|
|
966
|
+
Manage the `container` background services (apiserver + helpers), logs, disk usage, DNS
|
|
967
|
+
domains, the default kernel, and system properties. **Group alias:** `s`. macOS hosts only.
|
|
968
|
+
|
|
969
|
+
```bash
|
|
970
|
+
container system <subcommand>
|
|
971
|
+
container s <subcommand>
|
|
972
|
+
```
|
|
973
|
+
|
|
974
|
+
Subcommands: `start`, `stop`, `status`, `version`, `logs`, `df`, `dns` (group), `kernel`
|
|
975
|
+
(group), `property` (group).
|
|
976
|
+
|
|
977
|
+
> A deeper guide to the `config.toml`/property schema, DNS, default-kernel selection, and data
|
|
978
|
+
> locations lives in `references/configuration.md`. This section documents the CLI surface.
|
|
979
|
+
|
|
980
|
+
---
|
|
981
|
+
|
|
982
|
+
### `container system start`
|
|
983
|
+
|
|
984
|
+
Start the container services (and optionally install a default kernel). Starts
|
|
985
|
+
`container-apiserver` and background services.
|
|
986
|
+
|
|
987
|
+
```bash
|
|
988
|
+
container system start [-a <app-root>] [--install-root <path>] [--log-root <path>] [--enable-kernel-install | --disable-kernel-install] [--timeout <seconds>]
|
|
989
|
+
```
|
|
990
|
+
|
|
991
|
+
| Flag | Value | Default | Description |
|
|
992
|
+
|------|-------|---------|-------------|
|
|
993
|
+
| `-a, --app-root` | `<path>` | app-data default | Root directory for application data. |
|
|
994
|
+
| `--install-root` | `<path>` | install default | Root directory for executables and plugins. |
|
|
995
|
+
| `--log-root` | `<path>` | (macOS log facility) | Root directory for log data. When set, services write only to files here (and `container system logs` shows nothing). Intended for short-term diagnostics: no aggregation, no rotation. |
|
|
996
|
+
| `--enable-kernel-install` / `--disable-kernel-install` | flag pair | prompt user | Whether to install the default kernel. Omit to be prompted interactively. |
|
|
997
|
+
| `--timeout` | `<seconds>` | system default | Seconds to wait for the API service to become responsive. |
|
|
998
|
+
|
|
999
|
+
```bash
|
|
1000
|
+
container system start
|
|
1001
|
+
container system start --enable-kernel-install
|
|
1002
|
+
```
|
|
1003
|
+
|
|
1004
|
+
---
|
|
1005
|
+
|
|
1006
|
+
### `container system stop`
|
|
1007
|
+
|
|
1008
|
+
Stop the services and deregister them from launchd.
|
|
1009
|
+
|
|
1010
|
+
```bash
|
|
1011
|
+
container system stop [-p <prefix>]
|
|
1012
|
+
```
|
|
1013
|
+
|
|
1014
|
+
| Flag | Value | Default | Description |
|
|
1015
|
+
|------|-------|---------|-------------|
|
|
1016
|
+
| `-p, --prefix` | `<prefix>` | `com.apple.container.` | Launchd prefix for the services to stop. |
|
|
1017
|
+
|
|
1018
|
+
---
|
|
1019
|
+
|
|
1020
|
+
### `container system status`
|
|
1021
|
+
|
|
1022
|
+
Check whether the services are running (sends a health check to the API server).
|
|
1023
|
+
|
|
1024
|
+
```bash
|
|
1025
|
+
container system status [-p <prefix>] [--format <format>]
|
|
1026
|
+
```
|
|
1027
|
+
|
|
1028
|
+
| Flag | Value | Default | Description |
|
|
1029
|
+
|------|-------|---------|-------------|
|
|
1030
|
+
| `-p, --prefix` | `<prefix>` | `com.apple.container.` | Launchd prefix for the services. |
|
|
1031
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
1032
|
+
|
|
1033
|
+
---
|
|
1034
|
+
|
|
1035
|
+
### `container system version`
|
|
1036
|
+
|
|
1037
|
+
> **⚠️ Requires 1.0.0+** (added after 0.7.1). The top-level `container --version` flag exists in
|
|
1038
|
+
> all versions; only the `system version` subcommand is newer.
|
|
1039
|
+
|
|
1040
|
+
Show CLI and (if reachable) API-server version info.
|
|
1041
|
+
|
|
1042
|
+
```bash
|
|
1043
|
+
container system version [--format <format>]
|
|
1044
|
+
```
|
|
1045
|
+
|
|
1046
|
+
| Flag | Value | Default | Description |
|
|
1047
|
+
|------|-------|---------|-------------|
|
|
1048
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
1049
|
+
|
|
1050
|
+
Table columns: `COMPONENT`, `VERSION`, `BUILD`, `COMMIT`. A second row for
|
|
1051
|
+
`container-apiserver` appears when the server answers the health check.
|
|
1052
|
+
|
|
1053
|
+
---
|
|
1054
|
+
|
|
1055
|
+
### `container system logs`
|
|
1056
|
+
|
|
1057
|
+
Show logs from the container services.
|
|
1058
|
+
|
|
1059
|
+
```bash
|
|
1060
|
+
container system logs [-f] [--last <period>]
|
|
1061
|
+
```
|
|
1062
|
+
|
|
1063
|
+
| Flag | Value | Default | Description |
|
|
1064
|
+
|------|-------|---------|-------------|
|
|
1065
|
+
| `-f, --follow` | flag | `false` | Follow log output. |
|
|
1066
|
+
| `--last` | `<period>` | `5m` | Fetch logs from the given period ago. Format `<number>[m\|h\|d]` (bare number = seconds). |
|
|
1067
|
+
|
|
1068
|
+
If services were started with `--log-root`, they log only to files and this command shows nothing.
|
|
1069
|
+
|
|
1070
|
+
```bash
|
|
1071
|
+
container system logs -f
|
|
1072
|
+
container system logs --last 1h
|
|
1073
|
+
```
|
|
1074
|
+
|
|
1075
|
+
---
|
|
1076
|
+
|
|
1077
|
+
### `container system df`
|
|
1078
|
+
|
|
1079
|
+
Show disk usage for images, containers, and volumes (total count, active count, size,
|
|
1080
|
+
reclaimable).
|
|
1081
|
+
|
|
1082
|
+
```bash
|
|
1083
|
+
container system df [--format <format>]
|
|
1084
|
+
```
|
|
1085
|
+
|
|
1086
|
+
| Flag | Value | Default | Description |
|
|
1087
|
+
|------|-------|---------|-------------|
|
|
1088
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
1089
|
+
|
|
1090
|
+
---
|
|
1091
|
+
|
|
1092
|
+
### `container system dns`
|
|
1093
|
+
|
|
1094
|
+
Manage local DNS domains for containers. **Requires administrator privileges** (`sudo`) for
|
|
1095
|
+
`create`/`delete`.
|
|
1096
|
+
|
|
1097
|
+
```bash
|
|
1098
|
+
container system dns <create|delete|list>
|
|
1099
|
+
```
|
|
1100
|
+
|
|
1101
|
+
#### `container system dns create`
|
|
1102
|
+
|
|
1103
|
+
```bash
|
|
1104
|
+
sudo container system dns create [--localhost <ip>] <domain-name>
|
|
1105
|
+
```
|
|
1106
|
+
|
|
1107
|
+
**Arguments:** `<domain-name>` (required).
|
|
1108
|
+
|
|
1109
|
+
| Flag | Value | Default | Description |
|
|
1110
|
+
|------|-------|---------|-------------|
|
|
1111
|
+
| `--localhost` | `<ip>` | — | IPv4 address to redirect to localhost. |
|
|
1112
|
+
|
|
1113
|
+
#### `container system dns delete (rm)`
|
|
1114
|
+
|
|
1115
|
+
```bash
|
|
1116
|
+
sudo container system dns delete <domain-name>
|
|
1117
|
+
sudo container system dns rm <domain-name>
|
|
1118
|
+
```
|
|
1119
|
+
|
|
1120
|
+
**Alias:** `rm`. **Arguments:** `<domain-name>` (required). No options beyond global.
|
|
1121
|
+
|
|
1122
|
+
#### `container system dns list (ls)`
|
|
1123
|
+
|
|
1124
|
+
```bash
|
|
1125
|
+
container system dns list [--format <format>] [-q]
|
|
1126
|
+
container system dns ls [--format <format>] [-q]
|
|
1127
|
+
```
|
|
1128
|
+
|
|
1129
|
+
**Alias:** `ls`.
|
|
1130
|
+
|
|
1131
|
+
| Flag | Value | Default | Description |
|
|
1132
|
+
|------|-------|---------|-------------|
|
|
1133
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
1134
|
+
| `-q, --quiet` | flag | `false` | Only output the domain. |
|
|
1135
|
+
|
|
1136
|
+
---
|
|
1137
|
+
|
|
1138
|
+
### `container system kernel set`
|
|
1139
|
+
|
|
1140
|
+
Install or update the Linux kernel used by the container runtime.
|
|
1141
|
+
|
|
1142
|
+
```bash
|
|
1143
|
+
container system kernel set [--arch <arch>] [--binary <path>] [--force] [--recommended] [--tar <tar>]
|
|
1144
|
+
```
|
|
1145
|
+
|
|
1146
|
+
| Flag | Value | Default | Description |
|
|
1147
|
+
|------|-------|---------|-------------|
|
|
1148
|
+
| `--arch` | `amd64\|arm64` | `arm64` | Architecture of the kernel binary. |
|
|
1149
|
+
| `--binary` | `<path>` | — | Path to the kernel file (or archive member if used with `--tar`). |
|
|
1150
|
+
| `--force` | flag | `false` | Overwrite an existing kernel of the same name. |
|
|
1151
|
+
| `--recommended` | flag | `false` | Download and install the recommended default kernel (takes precedence over all other flags). |
|
|
1152
|
+
| `--tar` | `<tar>` | — | Filesystem path or remote URL to a tar archive containing a kernel file. |
|
|
1153
|
+
|
|
1154
|
+
```bash
|
|
1155
|
+
container system kernel set --recommended
|
|
1156
|
+
container system kernel set --binary ./vmlinux --arch arm64 --force
|
|
1157
|
+
container system kernel set --tar https://example.com/kernel.tar --binary boot/vmlinux
|
|
1158
|
+
```
|
|
1159
|
+
|
|
1160
|
+
---
|
|
1161
|
+
|
|
1162
|
+
### `container system property list (ls)`
|
|
1163
|
+
|
|
1164
|
+
List system properties with current values. **Alias:** `ls`.
|
|
1165
|
+
|
|
1166
|
+
```bash
|
|
1167
|
+
container system property list [--format <format>]
|
|
1168
|
+
container system property ls [--format <format>]
|
|
1169
|
+
```
|
|
1170
|
+
|
|
1171
|
+
| Flag | Value | Default | Description |
|
|
1172
|
+
|------|-------|---------|-------------|
|
|
1173
|
+
| `--format` | `json\|toml` | `toml` | Output format. Note: only `json`/`toml` here (not the full `ListFormat` set). |
|
|
1174
|
+
|
|
1175
|
+
```bash
|
|
1176
|
+
container system property list
|
|
1177
|
+
container system property list --format json
|
|
1178
|
+
```
|
|
1179
|
+
|
|
1180
|
+
---
|
|
1181
|
+
|
|
1182
|
+
## Network (macOS 26+)
|
|
1183
|
+
|
|
1184
|
+
> **Availability:** the entire `container network` group requires **macOS 26 or later**. On
|
|
1185
|
+
> macOS 15 the command group is absent and only a single default subnet is available.
|
|
1186
|
+
|
|
1187
|
+
Manage user-defined container networks. **Group alias:** `n`.
|
|
1188
|
+
|
|
1189
|
+
```bash
|
|
1190
|
+
container network <subcommand>
|
|
1191
|
+
container n <subcommand>
|
|
1192
|
+
```
|
|
1193
|
+
|
|
1194
|
+
Subcommands: `create`, `delete`/`rm`, `list`/`ls`, `inspect`, `prune`.
|
|
1195
|
+
|
|
1196
|
+
---
|
|
1197
|
+
|
|
1198
|
+
### `container network create`
|
|
1199
|
+
|
|
1200
|
+
Create a network.
|
|
1201
|
+
|
|
1202
|
+
```bash
|
|
1203
|
+
container network create [--internal] [--label <label> ...] [--option <option> ...] [--plugin <plugin>] [--subnet <subnet>] [--subnet-v6 <subnet-v6>] <name>
|
|
1204
|
+
```
|
|
1205
|
+
|
|
1206
|
+
**Arguments:** `<name>` (required).
|
|
1207
|
+
|
|
1208
|
+
| Flag | Value | Default | Description |
|
|
1209
|
+
|------|-------|---------|-------------|
|
|
1210
|
+
| `--internal` | flag | `false` | Restrict to a host-only network (NAT otherwise). |
|
|
1211
|
+
| `--label` | `<key=value>` | — | Network metadata. Repeatable. |
|
|
1212
|
+
| `--option` | `<key=value>` | — | Plugin-specific option. Repeatable. |
|
|
1213
|
+
| `--plugin` | `<plugin>` | `container-network-vmnet` | Network plugin to use. |
|
|
1214
|
+
| `--subnet` | `<cidr>` | — | IPv4 subnet (e.g. `192.168.100.0/24`). |
|
|
1215
|
+
| `--subnet-v6` | `<cidr>` | — | IPv6 prefix (e.g. `fd00:1234::/64`). |
|
|
1216
|
+
|
|
1217
|
+
```bash
|
|
1218
|
+
container network create mynet
|
|
1219
|
+
container network create --subnet 192.168.100.0/24 mynet
|
|
1220
|
+
container network create --internal isolated
|
|
1221
|
+
```
|
|
1222
|
+
|
|
1223
|
+
---
|
|
1224
|
+
|
|
1225
|
+
### `container network delete (rm)`
|
|
1226
|
+
|
|
1227
|
+
Delete one or more networks. **Alias:** `rm`.
|
|
1228
|
+
|
|
1229
|
+
```bash
|
|
1230
|
+
container network delete [-a] [<network-names> ...]
|
|
1231
|
+
container network rm [-a] [<network-names> ...]
|
|
1232
|
+
```
|
|
1233
|
+
|
|
1234
|
+
**Arguments:** `<network-names>` (zero or more; nothing deleted without names unless `-a`).
|
|
1235
|
+
|
|
1236
|
+
| Flag | Value | Default | Description |
|
|
1237
|
+
|------|-------|---------|-------------|
|
|
1238
|
+
| `-a, --all` | flag | `false` | Delete all networks. |
|
|
1239
|
+
|
|
1240
|
+
```bash
|
|
1241
|
+
container network delete mynet
|
|
1242
|
+
container network rm net1 net2
|
|
1243
|
+
container network delete --all
|
|
1244
|
+
```
|
|
1245
|
+
|
|
1246
|
+
---
|
|
1247
|
+
|
|
1248
|
+
### `container network list (ls)`
|
|
1249
|
+
|
|
1250
|
+
List user-defined networks. **Alias:** `ls`.
|
|
1251
|
+
|
|
1252
|
+
```bash
|
|
1253
|
+
container network list [--format <format>] [-q]
|
|
1254
|
+
container network ls [--format <format>] [-q]
|
|
1255
|
+
```
|
|
1256
|
+
|
|
1257
|
+
| Flag | Value | Default | Description |
|
|
1258
|
+
|------|-------|---------|-------------|
|
|
1259
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
1260
|
+
| `-q, --quiet` | flag | `false` | Only output the network name. |
|
|
1261
|
+
|
|
1262
|
+
---
|
|
1263
|
+
|
|
1264
|
+
### `container network inspect`
|
|
1265
|
+
|
|
1266
|
+
Print detailed info for one or more networks.
|
|
1267
|
+
|
|
1268
|
+
```bash
|
|
1269
|
+
container network inspect <networks> ...
|
|
1270
|
+
```
|
|
1271
|
+
|
|
1272
|
+
**Arguments:** `<networks>` (one or more, required). No options beyond global.
|
|
1273
|
+
|
|
1274
|
+
---
|
|
1275
|
+
|
|
1276
|
+
### `container network prune`
|
|
1277
|
+
|
|
1278
|
+
Remove networks not connected to any containers. Default and system networks are preserved.
|
|
1279
|
+
|
|
1280
|
+
```bash
|
|
1281
|
+
container network prune
|
|
1282
|
+
```
|
|
1283
|
+
|
|
1284
|
+
No arguments, no options beyond global.
|
|
1285
|
+
|
|
1286
|
+
---
|
|
1287
|
+
|
|
1288
|
+
## Volume
|
|
1289
|
+
|
|
1290
|
+
Manage persistent volumes. **Group alias:** `v`. Volumes may be created explicitly or
|
|
1291
|
+
implicitly (`-v myvol:/path`, or `-v /path` for an anonymous volume).
|
|
1292
|
+
|
|
1293
|
+
```bash
|
|
1294
|
+
container volume <subcommand>
|
|
1295
|
+
container v <subcommand>
|
|
1296
|
+
```
|
|
1297
|
+
|
|
1298
|
+
Subcommands: `create`, `delete`/`rm`, `list`/`ls`, `inspect`, `prune`.
|
|
1299
|
+
|
|
1300
|
+
---
|
|
1301
|
+
|
|
1302
|
+
### `container volume create`
|
|
1303
|
+
|
|
1304
|
+
Create a named volume.
|
|
1305
|
+
|
|
1306
|
+
```bash
|
|
1307
|
+
container volume create [--label <label> ...] [--opt <opt> ...] [-s <size>] <name>
|
|
1308
|
+
```
|
|
1309
|
+
|
|
1310
|
+
**Arguments:** `<name>` (required).
|
|
1311
|
+
|
|
1312
|
+
| Flag | Value | Default | Description |
|
|
1313
|
+
|------|-------|---------|-------------|
|
|
1314
|
+
| `--label` | `<key=value>` | — | Volume metadata. Repeatable. |
|
|
1315
|
+
| `--opt` | `<key=value>` | — | Driver-specific option. Repeatable. |
|
|
1316
|
+
| `-s` | `<size>` | — | Volume size in bytes; optional `K`/`M`/`G`/`T`/`P` suffix. Takes precedence over `--opt size=`. |
|
|
1317
|
+
|
|
1318
|
+
**Driver options** (`--opt key=value`, default `local` driver):
|
|
1319
|
+
|
|
1320
|
+
- `size=<value>` — volume size (unit suffixes as above; min 1 MiB). Equivalent to `-s`; `-s` wins if both set.
|
|
1321
|
+
- `journal=<mode>[:<size>]` — ext4 journaling. `<mode>` ∈ `ordered` (metadata only, data-before-metadata; kernel default), `writeback` (metadata only, no data ordering; fastest, least safe), `journal` (metadata + data; safest). Optional `:<size>` sets the journal size.
|
|
1322
|
+
|
|
1323
|
+
```bash
|
|
1324
|
+
container volume create --opt journal=ordered myvol
|
|
1325
|
+
container volume create --opt journal=writeback:64m myvol
|
|
1326
|
+
container volume create --opt journal=journal --opt size=10g myvol
|
|
1327
|
+
container volume create -s 5G data
|
|
1328
|
+
```
|
|
1329
|
+
|
|
1330
|
+
**Anonymous volumes:** auto-created with `-v /path` or `--mount type=volume,dst=/path` (UUID
|
|
1331
|
+
name `anon-…`). Unlike Docker, they do **not** auto-clean with `--rm` — delete manually.
|
|
1332
|
+
|
|
1333
|
+
```bash
|
|
1334
|
+
container run -v /data alpine
|
|
1335
|
+
VOL=$(container volume list -q | grep anon); container volume rm "$VOL"
|
|
1336
|
+
```
|
|
1337
|
+
|
|
1338
|
+
---
|
|
1339
|
+
|
|
1340
|
+
### `container volume delete (rm)`
|
|
1341
|
+
|
|
1342
|
+
Delete one or more volumes. Volumes in use (by running or stopped containers) cannot be deleted.
|
|
1343
|
+
**Alias:** `rm`.
|
|
1344
|
+
|
|
1345
|
+
```bash
|
|
1346
|
+
container volume delete [-a] [<names> ...]
|
|
1347
|
+
container volume rm [-a] [<names> ...]
|
|
1348
|
+
```
|
|
1349
|
+
|
|
1350
|
+
**Arguments:** `<names>` (zero or more; nothing deleted without names unless `-a`).
|
|
1351
|
+
|
|
1352
|
+
| Flag | Value | Default | Description |
|
|
1353
|
+
|------|-------|---------|-------------|
|
|
1354
|
+
| `-a, --all` | flag | `false` | Delete all volumes. |
|
|
1355
|
+
|
|
1356
|
+
```bash
|
|
1357
|
+
container volume delete myvol
|
|
1358
|
+
container volume delete vol1 vol2 vol3
|
|
1359
|
+
container volume delete --all
|
|
1360
|
+
```
|
|
1361
|
+
|
|
1362
|
+
---
|
|
1363
|
+
|
|
1364
|
+
### `container volume list (ls)`
|
|
1365
|
+
|
|
1366
|
+
List volumes. **Alias:** `ls`.
|
|
1367
|
+
|
|
1368
|
+
```bash
|
|
1369
|
+
container volume list [--format <format>] [-q]
|
|
1370
|
+
container volume ls [--format <format>] [-q]
|
|
1371
|
+
```
|
|
1372
|
+
|
|
1373
|
+
| Flag | Value | Default | Description |
|
|
1374
|
+
|------|-------|---------|-------------|
|
|
1375
|
+
| `--format` | `json\|table\|yaml\|toml` | `table` | Output format. |
|
|
1376
|
+
| `-q, --quiet` | flag | `false` | Only output the volume name. |
|
|
1377
|
+
|
|
1378
|
+
---
|
|
1379
|
+
|
|
1380
|
+
### `container volume inspect`
|
|
1381
|
+
|
|
1382
|
+
Print detailed info for one or more volumes as JSON.
|
|
1383
|
+
|
|
1384
|
+
```bash
|
|
1385
|
+
container volume inspect <names> ...
|
|
1386
|
+
```
|
|
1387
|
+
|
|
1388
|
+
**Arguments:** `<names>` (one or more, required). No options beyond global.
|
|
1389
|
+
|
|
1390
|
+
---
|
|
1391
|
+
|
|
1392
|
+
### `container volume prune`
|
|
1393
|
+
|
|
1394
|
+
Remove all volumes with no container references; reports disk space reclaimed.
|
|
1395
|
+
|
|
1396
|
+
```bash
|
|
1397
|
+
container volume prune
|
|
1398
|
+
```
|
|
1399
|
+
|
|
1400
|
+
No arguments, no options beyond global.
|
|
1401
|
+
|
|
1402
|
+
---
|
|
1403
|
+
|
|
1404
|
+
## Machine
|
|
1405
|
+
|
|
1406
|
+
> **⚠️ Requires 1.0.0+** — the entire `container machine` group was added after 0.7.1. Verify with
|
|
1407
|
+
> `container machine --help` on your install.
|
|
1408
|
+
|
|
1409
|
+
Manage container machines (the Linux VMs that host containers). **Group alias:** `m`.
|
|
1410
|
+
Commands that take an optional machine ID use the **default** machine when omitted. Changes to
|
|
1411
|
+
a running machine's config take effect after stop + restart.
|
|
1412
|
+
|
|
1413
|
+
```bash
|
|
1414
|
+
container machine <subcommand>
|
|
1415
|
+
container m <subcommand>
|
|
1416
|
+
```
|
|
1417
|
+
|
|
1418
|
+
Subcommands: `create`, `run`, `set`, `set-default`, `list`/`ls`, `inspect`, `logs`, `stop`, `delete`/`rm`.
|
|
1419
|
+
|
|
1420
|
+
---
|
|
1421
|
+
|
|
1422
|
+
### `container machine create`
|
|
1423
|
+
|
|
1424
|
+
Create a container machine from an image and boot it (unless `--no-boot`).
|
|
1425
|
+
|
|
1426
|
+
```bash
|
|
1427
|
+
container machine create [<options>] <image>
|
|
1428
|
+
```
|
|
1429
|
+
|
|
1430
|
+
**Arguments:** `<image>` (e.g. `alpine:3.22`, required).
|
|
1431
|
+
|
|
1432
|
+
| Flag | Value | Default | Description |
|
|
1433
|
+
|------|-------|---------|-------------|
|
|
1434
|
+
| `-n, --name` | `<name>` | — | Name for the machine. |
|
|
1435
|
+
| `--set-default` | flag | `false` | Set this machine as the default. |
|
|
1436
|
+
| `--no-boot` | flag | `false` | Create without booting. |
|
|
1437
|
+
| `--cpus` | `<n>` | — | Number of virtual CPUs. |
|
|
1438
|
+
| `--memory` | `<size>` | half of system memory | Memory allocation (e.g. `2G`, `8G`). |
|
|
1439
|
+
| `--home-mount` | `ro\|rw\|none` | `rw` | How to mount the user's home directory. |
|
|
1440
|
+
| `--virtualization` | flag | `false` | Enable nested virtualization. Requires Apple silicon M3+, macOS 15+, and a kernel with `CONFIG_KVM=y`. |
|
|
1441
|
+
| `--kernel` | `<path>` | — | Path to a custom kernel binary (e.g. `vmlinux`). |
|
|
1442
|
+
| `-a, --arch` | `<arch>` | host arch | Arch for a multi-arch image. |
|
|
1443
|
+
| `--os` | `<os>` | `linux` | OS for a multi-OS image. |
|
|
1444
|
+
| `--platform` | `<platform>` | — | Platform for a multi-platform image; precedence over `--os`/`--arch`. |
|
|
1445
|
+
| `--scheme` | `http\|https\|auto` | `auto` | Registry connection scheme. |
|
|
1446
|
+
| `--progress` | `auto\|none\|ansi\|plain\|color` | `auto` | Progress type. |
|
|
1447
|
+
| `--max-concurrent-downloads` | `<n>` | `3` | Max concurrent blob downloads. |
|
|
1448
|
+
|
|
1449
|
+
```bash
|
|
1450
|
+
container machine create alpine:3.22 --name my-machine
|
|
1451
|
+
container machine create --cpus 4 --memory 8G --set-default alpine:3.22
|
|
1452
|
+
container machine create --no-boot alpine:3.22
|
|
1453
|
+
container machine create --virtualization --kernel ./vmlinux-kvm alpine:3.22
|
|
1454
|
+
```
|
|
1455
|
+
|
|
1456
|
+
---
|
|
1457
|
+
|
|
1458
|
+
### `container machine run`
|
|
1459
|
+
|
|
1460
|
+
Run a command in a machine (booting it first if needed). With no command, opens an interactive
|
|
1461
|
+
login shell. Runs as a user matching the host user unless `--root`.
|
|
1462
|
+
|
|
1463
|
+
```bash
|
|
1464
|
+
container machine run [<options>] [<executable>] [<arguments> ...]
|
|
1465
|
+
```
|
|
1466
|
+
|
|
1467
|
+
**Arguments:** `<executable>` (default: login shell) · `<arguments>` (passthrough).
|
|
1468
|
+
|
|
1469
|
+
| Flag | Value | Default | Description |
|
|
1470
|
+
|------|-------|---------|-------------|
|
|
1471
|
+
| `-n, --name` | `<name>` | default machine | Machine ID. |
|
|
1472
|
+
| `-d, --detach` | flag | `false` | Run detached. |
|
|
1473
|
+
| `--root` | flag | `false` | Run as root instead of matching the host user. |
|
|
1474
|
+
|
|
1475
|
+
Plus the Process options group (`-e/--env`, `--env-file`, `--gid`, `-i/--interactive`,
|
|
1476
|
+
`-t/--tty`, `-u/--user`, `--uid`, `-w/--workdir/--cwd`).
|
|
1477
|
+
|
|
1478
|
+
```bash
|
|
1479
|
+
container machine run
|
|
1480
|
+
container machine run -n my-machine uname -a
|
|
1481
|
+
container machine run -n my-machine -- cat /proc/cpuinfo
|
|
1482
|
+
```
|
|
1483
|
+
|
|
1484
|
+
---
|
|
1485
|
+
|
|
1486
|
+
### `container machine set`
|
|
1487
|
+
|
|
1488
|
+
Set config values on a machine (applied after stop + restart).
|
|
1489
|
+
|
|
1490
|
+
```bash
|
|
1491
|
+
container machine set [-n <name>] <setting> ...
|
|
1492
|
+
```
|
|
1493
|
+
|
|
1494
|
+
**Arguments:** `<setting>` (one or more `key=value`).
|
|
1495
|
+
|
|
1496
|
+
| Flag | Value | Default | Description |
|
|
1497
|
+
|------|-------|---------|-------------|
|
|
1498
|
+
| `-n, --name` | `<name>` | default machine | Machine ID. |
|
|
1499
|
+
|
|
1500
|
+
**Settings:** `cpus=<n>` · `memory=<size>` (e.g. `2G`; default half of system memory) ·
|
|
1501
|
+
`home-mount=<ro\|rw\|none>` (default `rw`) · `virtualization=<true\|false>` (M3+, macOS 15+,
|
|
1502
|
+
`CONFIG_KVM=y`) · `kernel=<path>` (empty `kernel=` clears the override → system default).
|
|
1503
|
+
|
|
1504
|
+
```bash
|
|
1505
|
+
container machine set cpus=4 memory=8G
|
|
1506
|
+
container machine set -n my-machine home-mount=ro
|
|
1507
|
+
container machine set virtualization=true kernel=/opt/kernels/vmlinux-kvm
|
|
1508
|
+
container machine set kernel= # clear custom kernel
|
|
1509
|
+
```
|
|
1510
|
+
|
|
1511
|
+
---
|
|
1512
|
+
|
|
1513
|
+
### `container machine set-default`
|
|
1514
|
+
|
|
1515
|
+
Set the default machine.
|
|
1516
|
+
|
|
1517
|
+
```bash
|
|
1518
|
+
container machine set-default <id>
|
|
1519
|
+
```
|
|
1520
|
+
|
|
1521
|
+
**Arguments:** `<id>` (required). No options beyond global.
|
|
1522
|
+
|
|
1523
|
+
---
|
|
1524
|
+
|
|
1525
|
+
### `container machine list (ls)`
|
|
1526
|
+
|
|
1527
|
+
List machines; the default is marked in the `DEFAULT` column. **Alias:** `ls`.
|
|
1528
|
+
|
|
1529
|
+
```bash
|
|
1530
|
+
container machine list [--format <format>] [-q]
|
|
1531
|
+
container machine ls [--format <format>] [-q]
|
|
1532
|
+
```
|
|
1533
|
+
|
|
1534
|
+
| Flag | Value | Default | Description |
|
|
1535
|
+
|------|-------|---------|-------------|
|
|
1536
|
+
| `--format` | `json\|table` | `table` | Output format. Note: machines support only `json`/`table` (not `yaml`/`toml`). |
|
|
1537
|
+
| `-q, --quiet` | flag | `false` | Only output the machine ID. |
|
|
1538
|
+
|
|
1539
|
+
---
|
|
1540
|
+
|
|
1541
|
+
### `container machine inspect`
|
|
1542
|
+
|
|
1543
|
+
Print detailed machine info as JSON. Uses the default machine if no ID given.
|
|
1544
|
+
|
|
1545
|
+
```bash
|
|
1546
|
+
container machine inspect [<id>]
|
|
1547
|
+
```
|
|
1548
|
+
|
|
1549
|
+
**Arguments:** `<id>` (optional; default machine if omitted). No options beyond global.
|
|
1550
|
+
|
|
1551
|
+
---
|
|
1552
|
+
|
|
1553
|
+
### `container machine logs`
|
|
1554
|
+
|
|
1555
|
+
Fetch a machine's logs. Follow, tail, or view the boot log. Default machine if no ID given.
|
|
1556
|
+
|
|
1557
|
+
```bash
|
|
1558
|
+
container machine logs [--boot] [-f] [-n <n>] [<id>]
|
|
1559
|
+
```
|
|
1560
|
+
|
|
1561
|
+
**Arguments:** `<id>` (optional; default machine if omitted).
|
|
1562
|
+
|
|
1563
|
+
| Flag | Value | Default | Description |
|
|
1564
|
+
|------|-------|---------|-------------|
|
|
1565
|
+
| `--boot` | flag | `false` | Show the boot log instead of stdio. |
|
|
1566
|
+
| `-f, --follow` | flag | `false` | Follow log output. |
|
|
1567
|
+
| `-n` | `<n>` | — (all) | Show the last `n` lines. `-n` is short-only. |
|
|
1568
|
+
|
|
1569
|
+
---
|
|
1570
|
+
|
|
1571
|
+
### `container machine stop`
|
|
1572
|
+
|
|
1573
|
+
Stop a running machine. Default machine if no ID given.
|
|
1574
|
+
|
|
1575
|
+
```bash
|
|
1576
|
+
container machine stop [<id>]
|
|
1577
|
+
```
|
|
1578
|
+
|
|
1579
|
+
**Arguments:** `<id>` (optional; default machine if omitted). No options beyond global.
|
|
1580
|
+
|
|
1581
|
+
---
|
|
1582
|
+
|
|
1583
|
+
### `container machine delete (rm)`
|
|
1584
|
+
|
|
1585
|
+
Delete a machine, stopping it first if running. If it was the default, set a new one with
|
|
1586
|
+
`container machine set-default`. **Alias:** `rm`.
|
|
1587
|
+
|
|
1588
|
+
```bash
|
|
1589
|
+
container machine delete <id>
|
|
1590
|
+
container machine rm <id>
|
|
1591
|
+
```
|
|
1592
|
+
|
|
1593
|
+
**Arguments:** `<id>` (required). No options beyond global.
|