# 使用 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
- **版本:** 0.88.0
- **来源摘要:** Reference implementation for the Development Containers specification
- **主页:** <https://containers.dev>
- **最后更新:** 2026-07-23T23:57:30Z
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- devcontainer (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 0.88.0
## 项目历史与用法

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
## 其他软件包管理器记录

- 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


## Combined YAML source

View the package source record on GitHub. [combined/devcontainer.yml](https://github.com/mxcl/pkgdb/blob/main/combined/devcontainer.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated configuration and credential file locations
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
