devbox README

项目的 README,来自 github.com/rudderlabs/devbox。合并为一个 markdown 文件:README.md。

DevBox: open-source autonomous engineering harness in your cloud. It plans the change, writes the code, runs the tests and reviews its own work, then opens a draft pull request.

DevBox runs on your infrastructure, with your model keys. It is built for a whole engineering org: one shared harness that picks up Linear, Jira and ClickUp tickets, answers on GitHub pull requests, works across your repos, and remembers what it learned in them. Join the community on rudderstack.com/devbox.

MIT License

Hand DevBox a ticket. It plans the change, writes the code, runs the tests, reviews its own work and opens a draft pull request. You review and merge. Comment on the pull request, and it pushes the fix to the same branch.

DevBox demo: a Linear issue is delegated to DevBox, it reviews its own diff, opens draft pull requests in each repo, and pushes a fix after a review comment. Click to watch the full video on YouTube.
Watch the full launch video (2 min)

Why we built it

We are RudderStack, a customer data infrastructure company. Since April our engineers have handed tickets to DevBox. Today it merges about 35% of our internal pull requests, with about an 80% merge rate. Read the story behind it.

Coding tools like Claude Code and Codex make one developer faster. We wanted the other half: a shared teammate the whole org can delegate to, that runs where our code and secrets already live, and that gets better at our repos over time. DevBox works alongside those tools.

Features

How it works

Tasks come in from the devbox CLI or Linear, and GitHub sends follow-ups on DevBox pull requests. The control plane (API, Postgres, no LLM calls) starts one sandbox per task through OpenSandbox. In the sandbox the harness plans, codes, tests, reviews and opens the PR, holding only placeholder tokens. iron-proxy swaps in the real tokens, allows GitHub writes only to your repos and LLM calls only to your endpoint.

docs/architecture.md has the details.

Quickstart

About 15 minutes, most of it the first image build. The steps assume macOS; see the notes below for Linux.

You need: Docker Desktop with 8 GB of memory for Docker (Compose 2.13 or newer), Bun 1.4.4 or newer, make, openssl, a GitHub token or gh logged in, and an OpenAI or Anthropic API key.

[!TIP] Prefer to let an agent do it? Run claude in the cloned repo and ask it to set up DevBox (other coding agents can read skills/devbox/). Run the bun run quickstart command it gives you yourself, so your keys go to its hidden prompts and never through the chat.

  1. Get the code.

    git clone https://github.com/rudderlabs/devbox.git && cd devbox
    
  2. Pick your repo and model. Copy the example config, then set your repo's URL and your LLM in it.

    cp devbox.config.example.json devbox.config.json
    
    {
      "repos": [{ "url": "https://github.com/your-org/your-repo.git", "branch": "main" }],
      "llm": { "provider": "openai", "baseUrl": "https://api.openai.com/v1", "model": "gpt-5.6-sol" }
    }
    

    DevBox only ever writes to the repos listed here. Anthropic and per-stage models: docs/configuration.md.

    Or skip this step: when there is no devbox.config.json, bun run quickstart asks for your repos and model and writes it.

  3. Start DevBox.

    bun run quickstart
    

    It checks your config and the tools you need, and asks whether to run on Docker Compose or a local kind cluster and whether to set up Linear and the GitHub App now (say no for a first try; Next steps adds them later). Then it starts DevBox with bun run up, which asks for your GitHub token (or takes it from gh) and your LLM key, and offers to save them in the macOS Keychain, never in a file. It builds the images (about 10 minutes the first time) and logs the CLI in.

  4. Give it a task.

    bun run devbox create "Add a /health endpoint to your-org/your-repo"
    

    It prints the task's key, for example DBX-API-1.

  5. Watch it work.

    bun run devbox logs -f DBX-API-1
    

    You see it orient, plan, review its plan, implement, test and review its own diff. At the end, a draft pull request opens on your repo, under your GitHub account.

  6. Ask for changes.

    bun run devbox send DBX-API-1 "Also add a test"
    

    It pushes new commits to the same pull request.

  7. Stop it.

    bun run down
    

    Your tasks are kept for the next bun run up. bun run reset deletes them.

Explore the CLI: bun run devbox --help lists every command: ls, show, wait, restart and more.

[!WARNING] Linux: add your user to the docker group (sudo usermod -aG docker $USER, then log out and back in). bun run up uses the Secret Service (libsecret) instead of the Keychain.

[!TIP] On a corporate network or VPN that blocks public DNS, run bun run up --dns-resolver <host:port> with a DNS server that works there. After you change devbox.config.json, run bun run up again. After you change the model, try it on a new task.

Task lifecycle

Task lifecycle: task, orient, plan, plan review (issues get one revision, not a re-review), implement, self-review, draft PR with a knowledge commit. You review; follow-ups from PR comments, @mentions, failed CI or devbox send go back to implement.

Next steps

Delegate an issue to DevBox, or @mention it, and it moves the issue to started, posts its progress in the issue's agent session and opens a draft pull request. Follow-ups in the session reach the task. Nobody on the team needs the CLI.

Linear sends webhooks, so it needs a public HTTPS URL that reaches port 3000 on your machine. With ngrok:

ngrok http 3000                                              # in another terminal
bun run linear:setup --public-url https://<your-tunnel-host> # registers the app in Linear
bun run up                                                   # applies it
bun run linear:status                                        # checks the URL reaches DevBox

linear:setup opens Linear's "create app" page, filled in for you. Click Create, then paste the client ID and the two secrets it asks for.

[!IMPORTANT] Tunnels on a laptop. A free tunnel gets a new URL each time it restarts, and Linear keeps sending to the old one. Use a URL that doesn't change: a free ngrok static domain (ngrok http --url=<your-domain> 3000) or a named Cloudflare tunnel. If the URL changed anyway, see When the public URL changes. If delegating does nothing, bun run linear:status tells you whether the URL reaches DevBox, and Troubleshooting maps each message to a fix.

docs/linear.md covers Kubernetes, private teams and rotating secrets.

Run tasks from Jira

Assign a Jira Cloud issue to DevBox's service account and it moves the issue to started, links the draft pull request and replies in comments. Comments that @mention it reach the task. It uses the same public URL as Linear.

bun run jira:setup --public-url https://<your-tunnel-host>   # checks the service account, prints the webhook
bun run up                                                   # applies it, once a Jira admin created the webhook
bun run jira:status

docs/jira.md covers the service account, the webhook, who is trusted, and rotating the token.

Run tasks from ClickUp

Add DevBox's bot, a member of your ClickUp workspace, to a task's assignees and it moves the task to started and replies in comments, with the draft pull request's link. Comments that @mention it reach the task. Setup creates the webhook through ClickUp's API, at the same public URL as Linear.

bun run clickup:setup --public-url https://<your-tunnel-host>   # checks the bot's token, creates the webhook
bun run up                                                      # applies it
bun run clickup:status

docs/clickup.md covers the bot, the webhook, who is trusted (never guests or automations), and changing the bot.

Let your team @mention DevBox on pull requests (GitHub App)

Your token alone is enough for DevBox to open pull requests. A GitHub App adds: commits from a bot instead of your account, tokens that refresh on their own, and @<app> mentions, reviews and failed CI runs on its pull requests that reach the task.

bun run github:setup --public-url https://<your-tunnel-host>   # same URL as Linear
bun run up
bun run github:status

docs/github.md covers the modes, trust lists and token scope.

Teach DevBox your repo

Put your conventions and build and test commands in AGENTS.md, CLAUDE.md or .agents/knowledge/. DevBox reads them before every task and adds what it learns there in each pull request (docs/extending.md).

Run on Kubernetes

A Helm chart runs each task in its own pod, with the same egress proxy. Try it locally with bun run k8s:kind, then follow docs/kubernetes/README.md for the installer, GitOps and the Amazon EKS guide.

Manage secrets

bun run secrets ls shows what DevBox saved in your keychain, and bun run secrets rm <NAME> removes one. Environment variables (GITHUB_TOKEN, LLM_API_KEY) win over saved values (docs/configuration.md).

Secure by default

The sandbox holds only placeholder tokens. iron-proxy swaps in the real tokens, allows GitHub writes only to your repos and LLM calls only to your endpoint. PR comments are read only from orgs and users you trust.

To report a vulnerability, see SECURITY.md.

Not in v1

FAQ

Can DevBox push to main or merge my pull requests?

It works on its own branch and opens draft pull requests. Merging stays with you, and your branch protection rules still apply.

Does my code leave my infrastructure?

Your code stays in your sandboxes and on GitHub. What the model needs to see goes to the LLM endpoint you configure, as with any coding tool.

Does DevBox send telemetry?

No. DevBox sends nothing to RudderStack. Tracing with Langfuse is optional, off by default, and goes to the Langfuse instance you set up.

Can a malicious issue or comment steal my keys?

The keys are never in the sandbox, so there is nothing to steal there. DevBox reads pull request comments only from people you trust. See Secure by default.

Why do the pull requests show up under my name?

With a personal token, DevBox acts as you. Set up the GitHub App to get a bot identity.

Do I need Linear, Jira or ClickUp?

No. The CLI does everything. Linear, Jira or ClickUp makes it a team tool: anyone can hand DevBox an issue without the CLI.

Does it replace Claude Code or Codex?

No. Those help one developer at the keyboard, and we use them every day. DevBox is the org's shared harness that picks up tickets in the background.

Docs

License

DevBox is open source and licensed under the MIT License.

devbox (rudderlabs/devbox)

正在搜索数据库…

338 ·GitHub
这是什么?DevBox 是一个开源的自主工程框架,需要部署在你自己的基础设施上。你把工单交给它,它会规划改动、编写代码、运行测试、审查自己的工作,然后为你打开一个草稿拉取请求(Pull Request),由你来合并。
它是像 Claude Code 那样的编码智能体,还是别的什么?是别的东西:它是整个工程团队共享的“队友”,会在后台接手工单。它与 Claude Code 和 Codex 协同工作,而后两者帮助的是坐在键盘前的单个开发者。
我该如何让它运行起来?克隆仓库,运行 bun run quickstart,将你的仓库和模型写入 devbox.config.json,然后运行 bun run up 构建镜像并启动它。首次构建镜像大约需要 10 分钟。
开始之前我需要准备什么?Docker Desktop,并为 Docker 分配 8 GB 内存(Compose 2.13 或更新版本);Bun 1.4.4 或更新版本;make;openssl;一个 GitHub 令牌或 gh 登录;以及一个 OpenAI 或 Anthropic 的 API 密钥。在 Linux 上,你还需要把当前用户添加到 docker 用户组。
它目前还不支持什么?不支持 Bitbucket 和 Jira,没有网页界面,也不能从 GitHub Issues 启动任务。新任务只能通过命令行(CLI)和 Linear 创建,目前还不支持从 Linear 停止任务。
我的密钥会泄露吗?模型能看到什么?沙箱中只保存占位令牌;出口代理会注入真实令牌,并且只允许写入你的仓库。代码保存在你的沙箱和 GitHub 上,模型所需的内容会发送到你设置的 LLM 端点,DevBox 不会向 RudderStack 发送任何遥测数据。
在编写任何代码之前,任务会经历什么?任务会先经过梳理情况与规划阶段,然后由审查员检查计划。如果发现问题,相关仓库的规划器会修订一次,且不再复审,之后才开始实施。
它会随着时间学习我仓库的约定吗?会。它在每个任务之前都会读取 AGENTS.md、CLAUDE.md 或 .agents/knowledge/,并把新的经验提炼成一次提交,作为拉取请求的一部分写入你的仓库,并像代码一样接受审查。
RudderStack 为什么要开发它?他们希望为整个团队打造一个共享的“队友”,让它运行在代码和密钥已经所在的地方,并随着时间推移越来越懂他们的仓库。目前它负责合并其内部约 35% 的拉取请求,合并率约为 80%。
大小
8.5 MB
星标
338
时长
22天
提交 · 90 天