{"id":"apple-container","name":"apple-container","summary":"Appleのオープンソースの「コンテナ」CLIは、AppleシリコンmacOS上でOCI/Linuxコンテナを軽量なコンテナごとのVMとして構築、実行、管理するためのもので、Dockerデーモンは不要です。","body":"# Apple `container`\n\nApple's `container` is an open-source CLI for building, running, and managing OCI/Linux\ncontainers on Apple-silicon Macs. Each container runs inside its own lightweight virtual\nmachine (backed by the Containerization framework and the Virtualization API), so there is no\nshared daemon like Docker — services run per-user via `launchd`. Images are standard OCI\nartifacts, so they interoperate with Docker registries and other OCI tooling. The CLI is\ndeliberately Docker-like (`container run`, `container build`, and image ops under\n`container image push`/`pull`), but it is a distinct tool: do not assume Docker command paths,\nflags, defaults, or daemon behavior carry over (e.g. there is no `container images`/`push`/`pull`\ntop-level command — image verbs live under `container image`).\n\n## Requirements\n\n- **Apple silicon only** (M1 or later). Intel Macs are not supported.\n- **macOS 26 (Tahoe) is the officially supported target.** The maintainers do not support\n  older macOS and typically will not fix issues that can't be reproduced on 26. The binary\n  still runs on **macOS 15 (Sequoia)** but with reduced networking: only the single default\n  subnet is available, and the `container network` group and `--network` flag error out.\n  macOS-26-gated features are called out throughout the reference files.\n- **Version:** this skill documents the **1.0.0** release (the fullest feature set). The `machine`\n  group, `container cp`, `container export`, `container prune`, `container image prune`,\n  `container registry list`, and `container system version` were **added in 1.0.0** (not in 0.7.1)\n  — features that postdate 0.7.1 are flagged *(1.0.0+)* in the reference files. Run `container --version` and\n  `container <group> --help` to see what your installed build supports.\n- Install by downloading the signed `.pkg` installer from the project's GitHub releases\n  (`apple/container`) and running it. See `references/concepts.md` for the full\n  requirements/compatibility matrix and how the VM-per-container model works.\n\n## Setup\n\nInstall the signed package, then start the background services once:\n\n1. **Download** the latest signed installer `.pkg` from the\n   [GitHub releases page](https://github.com/apple/container/releases).\n2. **Double-click** the downloaded package and follow the prompts, entering your admin\n   password so it can place files under `/usr/local`. (There is no documented CLI `installer`\n   invocation — installation is via the GUI package.)\n3. **Start the services** and confirm they are healthy:\n\n```bash\n# Start the container services (container-apiserver + helpers via launchd). On first run it\n# offers to install the default Linux kernel — accept it, or start non-interactively with\n# `--disable-kernel-install` and add a kernel later via `container system kernel set`.\ncontainer system start\n\n# Verify services are healthy\ncontainer system status\n```\n\n`container system start` must have run before any container/image/build command works — a\nconnection/XPC error almost always means the services are stopped, so run it again. Stop and\nderegister the `launchd` services with `container system stop` (which takes only `-p/--prefix`).\nThe startup flags for `container system start` (`-a/--app-root`, `--install-root`, `--log-root`,\n`--enable-kernel-install`/`--disable-kernel-install`, `--timeout`) are in\n`references/configuration.md`.\n\n**Upgrade / downgrade / uninstall** use helper scripts in `/usr/local/bin` (stop first with\n`container system stop`): `update-container.sh` (add `-v <version>` to pin a version), and\n`uninstall-container.sh -d` to remove user data or `-k` to keep it. Full recipes in\n`references/workflows.md`.\n\n## Command groups at a glance\n\nInvoke everything as `container <group> <subcommand>`. Container-lifecycle verbs (`run`,\n`create`, `start`, `stop`, `exec`, `logs`, `inspect`, `list`/`ls`, `delete`/`rm`, `kill`,\n`stats`) and `build` are top-level; image operations like `push`, `pull`, and `tag` live\nunder `container image`. Run `container <group> --help` for exact flags, or read\n`references/commands.md` for the exhaustive matrix.\n\n| Group | What it does | Example |\n|-------|--------------|---------|\n| container lifecycle | Create, start, run, stop, exec, inspect, list, remove containers | `container run --rm -it docker.io/library/alpine sh` |\n| build | Build an OCI image from a Dockerfile in the builder VM | `container build -t myapp:latest .` |\n| image | List, tag, inspect, remove, load/save, prune local images; push/pull to registries | `container image ls` |\n| registry | Authenticate (login/logout/list) to OCI registries | `container registry login ghcr.io` |\n| system | Start/stop/status services, logs, disk usage (`df`), DNS, kernel, properties | `container system status` |\n| network | Create/list/remove container networks (**macOS 26 only**) | `container network create mynet` |\n| volume | Create/list/inspect/remove persistent volumes | `container volume create data` |\n| builder | Manage the builder VM that runs `container build` (start/stop/status) | `container builder status` |\n| machine *(1.0.0+)* | Persistent Linux \"machine\" environments (added in 1.0.0) | `container machine --help` |\n\nExact subcommand names, aliases, arguments, and flags for each group live in\n`references/commands.md` — consult it before running an unfamiliar command rather than\nguessing Docker-equivalent syntax.\n\n## Navigating this skill\n\nRead the reference file that matches the task; do not guess flags or behavior.\n\n- **`references/commands.md`** — exhaustive CLI reference: every command group, subcommand,\n  alias, argument, and flag. Read this to construct any concrete `container ...` invocation,\n  or to confirm a flag exists before using it.\n- **`references/concepts.md`** — architecture (VM-per-container, Containerization framework),\n  system requirements and macOS 15 vs 26 differences, networking model, per-container IPs,\n  security model, and a Docker-vs-`container` comparison. Read this to explain how or why\n  something works, or when a Docker mental model gives the wrong answer.\n- **`references/configuration.md`** — the system service, `config.toml` / property model,\n  default kernel, DNS domains, default registry, builder resources, and machine settings.\n  Read this to change defaults, tune CPU/memory, point at a private registry, or manage the\n  kernel.\n- **`references/workflows.md`** — copy-pasteable task recipes (run an image, build & push,\n  wire up local DNS, mount a volume, expose ports) and troubleshooting for common failures.\n  Read this first when the user wants to accomplish a concrete end-to-end task.\n\n## Key rules\n\n- **This is not Docker.** The CLI resembles Docker, but flags, defaults, and daemon behavior\n  differ. Verify syntax in `references/commands.md` instead of assuming Docker equivalence.\n- **Always ensure services are up first.** Run `container system start` (and confirm with\n  `container system status`) before any container/image/build command; connection errors\n  usually mean the services are stopped.\n- **Images are standard OCI artifacts** and interoperate with Docker registries and other OCI\n  tools. Image references that omit a registry default to `docker.io` (configurable via the\n  `registry.domain` property — see `references/configuration.md`).\n- **Each container gets its own IP address** on its network (one lightweight VM per\n  container). There is no shared Docker bridge; reach a container directly by its IP, or set\n  up a local DNS domain (`container system dns create ...`, admin required) for name-based\n  access.\n- **`container network` requires macOS 26.** On macOS 15 only the single default subnet is\n  available and the network command group is unavailable — see `references/concepts.md`.\n- **Use fully-qualified image references** when precision matters (e.g.\n  `docker.io/library/alpine` rather than bare `alpine`) to avoid ambiguity about the source\n  registry.","author":"@sanjay3290","ownerProfile":null,"authorContacts":null,"sourceUrl":"https://github.com/sanjay3290/ai-skills/tree/main/skills/apple-container","license":"Apache-2.0","category":"devops","lang":"en","tokens":1875,"stars":0,"calls30d":2,"claimed":false,"visibility":"public","origin":"crawler","version":"0.1.0","createdAt":"2026-08-22","updatedAt":"2026-08-22","files":[{"path":"references/commands.md","size":54119,"sha256":"10d3b1a05da33baa411a8c93682eaedb616f82494e7d272109bf9f932000db55"},{"path":"references/concepts.md","size":18001,"sha256":"3d738dfe84905dd3dce5929f22cb7489050e5be0e60bc829921c50f7cce0871d"},{"path":"references/configuration.md","size":25402,"sha256":"e4796411607e21078b97f7d98e86fc12a3c4a0f77c1daabf8f0dc61cc541c6da"},{"path":"references/workflows.md","size":17908,"sha256":"e3caf70678401b9c657e8793026ab6b44294051bc00a0c7143c66169ef42f217"}],"requires":{"mcp":[],"tools":[]},"safety":{"flags":[],"scannedAt":"2026-08-22","hasScripts":false,"networkEndpoints":["ex.com","my-web-server.test"]}}