# 使用 Homebrew, Nix 安装 code-server

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

## 安装

```sh
sudo av install brew:code-server
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install code-server
```

  证据: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#code-server
```

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

## 软件包事实

- **软件包键:** brew:code-server
- **软件包管理器:** Homebrew
- **版本:** 4.112.0
- **来源摘要:** Access VS Code through the browser
- **主页:** <https://coder.com>
- **最后更新:** 2026-06-15T10:20:13-04:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- code-server (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

code-server is Coder's project for running VS Code on a remote machine and accessing it through a browser. It packages the VS Code editing experience as a self-hosted web IDE with a `code-server` CLI, install script, service setup, and browser login flow.

### 项目历史

The GitHub repository was created in 2019. The official contributing docs describe the early v1 architecture as a Code submodule plus a large patch that split the UI into a browser front-end and a server process. As VS Code's web architecture matured, code-server v2 and later used the Code front-end while implementing the server side, later reducing its patch set as upstream Code opened more server pieces.

### 采用历史

code-server became a standard self-hosted way to get VS Code in a browser, especially for remote Linux machines and cloud development boxes. Official docs support install scripts, Debian and RPM packages, AUR, Homebrew, Docker, Helm, Raspberry Pi, Termux, and cloud-provider guides; the input also records Homebrew and Nix distribution.

### 使用方式

Typical use is installing `code-server`, starting it as a user service or container, then visiting localhost or a secured remote URL in a browser. The default config is created at `~/.config/code-server/config.yaml`, stores bind address, auth mode, password or hashed password, and TLS settings, and can be overridden by flags or environment variables.

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

For package nerds, code-server is significant because it turns a large desktop editor into a service-oriented CLI package. Its packaging story spans native packages, Homebrew, Nix, Docker images, Helm charts, AUR recipes, install scripts, and upstream VS Code version tracking, which makes it a useful case study in repackaging a fast-moving Electron editor for headless and server environments.

### 时间线

- 2019: GitHub repository for coder/code-server created.
- 2019: v1 architecture split Code into browser front-end and server pieces, according to official contributing docs.
- 2022: v4 releases tracked upstream VS Code versions in the changelog.
- 2026: Recent releases continued tracking current VS Code versions.

### Related projects

- Related projects and comparators include Visual Studio Code, Code OSS, Coder, Theia, OpenVSCode Server, GitHub Codespaces, VS Code web, devcontainers, and remote development tooling.

### 来源

- <https://github.com/coder/code-server>
- <https://coder.com/docs/code-server/FAQ>
- <https://coder.com/docs/code-server/install>
- <https://coder.com/docs/code-server/CONTRIBUTING>
- <https://github.com/coder/code-server/releases>


## 安全说明

broad file, network, media, or database tool signal. formula declares a Homebrew service.

- **Geiger 风险:** orange / 中
- broad file, network, media, or database tool signal
- formula declares a Homebrew service


## 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: ~/.config/code-server/config.yaml

## Credential files

- Unix: ~/.config/code-server/config.yaml
## 其他软件包管理器记录

- Nix - code-server: normalized package name match | nixpkgs package indexes: pkgs/by-name/co/code-server/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/code-server.yml](https://github.com/mxcl/pkgdb/blob/main/combined/code-server.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
