# 使用 Homebrew, Nix 安装 devcontainer

查看 devcontainer 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:devcontainer
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install devcontainer
```

  证据: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#devcontainer
```

  证据: nixpkgs package indexes: pkgs/by-name/de/devcontainer/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## 软件包事实

- **软件包键:** brew:devcontainer
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/devcontainer>
- **版本:** 0.87.0
- **来源摘要:** Reference implementation for the Development Containers specification
- **主页:** <https://containers.dev>
- **仓库:** <https://github.com/devcontainers/cli>
- **上游文档:** <https://containers.dev/>
- **许可证:** MIT
- **源码归档:** <https://registry.npmjs.org/@devcontainers/cli/-/cli-0.87.0.tgz>
- **最后更新:** 2026-05-13T13:00:10Z
- **已生成:** 2026-07-09T07:20:21+00:00

## 可执行文件

- devcontainer (cli)
- devcontainer (别名)

## 依赖

- node

## 安装行为

- post-install 钩子: 未定义
- Bottle: 可用 于 all

## 版本和新鲜度

- 页面生成时间: 2026-07-09
- 管理器版本: 0.87.0
- 管理器更新时间: 2026-05-13
- 本地数据: OK
- 上游仓库: https://containers.dev
- 信息: Release/tag comparison is only available for GitHub repositories.
## 项目历史与用法

Dev Container CLI is the reference command-line implementation for the Development Containers specification. It reads devcontainer.json metadata and creates, builds, configures, and runs development containers outside a single editor UI.

### 项目历史

The devcontainers/spec repository was created in January 2022, and devcontainers/cli followed in April 2022. The CLI changelog starts with 0.1.0 as the initial version and then quickly adds build, feature, template, metadata, and lifecycle support through the 2022 releases.

### 采用历史

The broader dev container format came from the need for structured metadata that tools could share, similar in spirit to the Language Server Protocol. The official supporting-tools page lists editors and services such as VS Code, Visual Studio, IntelliJ IDEA, GitHub Codespaces, and the standalone Dev Container CLI as participants in the ecosystem.

### 使用方式

Package users install the devcontainer executable, keep devcontainer.json in a project, and run commands such as devcontainer up, build, exec, read-configuration, features, and templates. The CLI README also frames it as useful for CI, where a project's development container can be reused as a build and test environment.

### 为什么软件包爱好者会关心

For package nerds, devcontainer is important because it turns editor-oriented development-environment metadata into a portable CLI contract. It bridges package managers, Docker or Podman-style container engines, OCI-distributed features, templates, GitHub Actions, Codespaces, and local development workflows.

### 时间线

- 2022: devcontainers/spec repository created.
- 2022: devcontainers/cli repository created.
- 2022: CLI 0.1.0 initial version appears in the changelog.
- 2022: CLI 0.12.0 added native feature publishing to OCI registries.
- 2026: CLI 0.87.0 made lockfile generation stable by default.

### Related projects

- Officially related projects include the Development Containers specification, Dev Container Features and Templates, devcontainers/ci, VS Code Dev Containers, GitHub Codespaces, Docker, Docker Compose, and supporting IDE integrations.

### 来源

- <https://containers.dev/>
- <https://containers.dev/overview>
- <https://containers.dev/supporting>
- <https://github.com/devcontainers/cli>
- <https://github.com/devcontainers/cli/blob/main/README.md>
- <https://github.com/devcontainers/cli/blob/main/CHANGELOG.md>
- <https://api.github.com/repos/devcontainers/cli>
- <https://api.github.com/repos/devcontainers/spec>


## 安全说明

infrastructure mutation or orchestration signal.

- **Geiger 风险:** orange / 中
- infrastructure mutation or orchestration signal


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: .devcontainer/devcontainer.json, .devcontainer.json
## 源数据库详情

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** devcontainer
- **Version Scheme:** 0
- **Revision:** 0
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

## 其他软件包管理器记录

- Nix - devcontainer: normalized package name match | nixpkgs package indexes: pkgs/by-name/de/devcontainer/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1


## 相关链接

- [Cloud CLI packages](https://www.automicvault.com/zh-hans/pkg/cloud-clis/) - Belongs to a cloud or infrastructure command family.
- [Secret-risk packages](https://www.automicvault.com/zh-hans/pkg/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://www.automicvault.com/zh-hans/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/zh-hans/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [node](https://www.automicvault.com/zh-hans/pkg/brew/node/) - Runtime dependency declared by Homebrew.
- [cdebug](https://www.automicvault.com/zh-hans/pkg/brew/cdebug/) - Shares av.db curated category or tags: cli, containers, developer-tools, docker.
- [cekit](https://www.automicvault.com/zh-hans/pkg/brew/cekit/) - Shares av.db curated category or tags: cli, containers, developer-tools, docker.
- [dockcheck](https://www.automicvault.com/zh-hans/pkg/brew/dockcheck/) - Shares av.db curated category or tags: cli, containers, developer-tools, docker.
- [docker](https://www.automicvault.com/zh-hans/pkg/brew/docker/) - Shares av.db curated category or tags: cli, containers, developer-tools, docker.
- [docker-buildx](https://www.automicvault.com/zh-hans/pkg/brew/docker-buildx/) - Shares av.db curated category or tags: cli, containers, developer-tools, docker.
- [docker-clean](https://www.automicvault.com/zh-hans/pkg/brew/docker-clean/) - Shares av.db curated category or tags: cli, containers, developer-tools, docker.
- [docker-compose](https://www.automicvault.com/zh-hans/pkg/brew/docker-compose/) - Shares av.db curated category or tags: cli, containers, developer-tools, development-environments, docker.
- [docker-credential-helper](https://www.automicvault.com/zh-hans/pkg/brew/docker-credential-helper/) - Shares av.db curated category or tags: cli, containers, developer-tools, docker.
- [envd](https://www.automicvault.com/zh-hans/pkg/brew/envd/) - Local package facts share a topical domain. Shared terms: cli, containers, developer, developer-tools, development.
- [dockly](https://www.automicvault.com/zh-hans/pkg/brew/dockly/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, containers, developer, developer-tools, docker.

## Combined YAML source

View the package source record on GitHub. [combined/devcontainer.yml](https://github.com/automic-vault/db/blob/main/combined/devcontainer.yml)


## 来源

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
