@balasivagn/boxci

中文文档
0.4.1发布于 2026/10/27Apache-2.0ES Module构建来源已验证近 30 天下载 2494

BoxCI: GitHub Actions on InstaBox. One setup, paused runners that wake for CI, optional local dashboard.

原始使用文档
文档目录9 节
  1. Quick start
  2. Set up with a coding agent
  3. How it works
  4. Commands
  5. Migrate existing jobs
  6. Limits
  7. Docs
  8. Contributing
  9. License

BoxCI

GitHub Actions runners on your own InstaBox VMs.
They wake up for CI and pause again when idle.

License: Apache-2.0 Node 22.23.4+ / 24.22.1+ npm version

Quick start · Use your agent · How it works · Commands · Migrate · Limits · Docs


BoxCI turns InstaBox VMs into dedicated GitHub Actions runners for your repository. Set up, migrate your existing CI, then run and monitor it, all from one CLI. No keepalive, no webhook server, no BoxCI account.

  • Reviewable. --dry-run shows the plan. Workflow changes stay local for you to review, commit and push.
  • Migrates existing CI. boxci migrate retargets jobs (Blacksmith, ubuntu-latest) as a local diff.
  • Agent-ready. Paste one prompt, or use the bundled migration skill.
  • Safe fallback. Fork PRs, or a pool that isn't ready, run on hosted ubuntu-24.04. Fork code never sees your provider key.
  • Read-only dashboard. boxci dashboard is local and authenticated, and never wakes a VM.

Quick start

Needs Node.js ^22.23.4 || >=24.22.1, Git, admin on a GitHub repo, and an InstaBox account with room for one more VM.

npm install -g @balasivagn/boxci
cd /path/to/your-app          # the repo whose CI you want to change

boxci init --dry-run          # preview, creates nothing
boxci init                    # approve the plan; writes .github/workflows/boxci-wake.yml
boxci migrate                 # pick existing jobs to move onto the pool

init and migrate only edit files locally. They never create a branch, commit, push or PR. Review git diff -- .github/workflows, commit and push it your usual way, merge to the default branch, then:

boxci ci run --workflow ci.yml
boxci status
Install tips
  • Older Node: npm only warns (EBADENGINE). --version and --help work, but setup stops with a certificate-trust error. Check node --version first.

  • boxci: command not found: put npm's global bin on PATH, or install to a user prefix:

    npm install -g --prefix "$HOME/.local" @balasivagn/boxci
    export PATH="$HOME/.local/bin:$PATH"
    
  • Update: rerun the install command.

  • Unreleased main: npm install -g https://github.com/balasivagn/boxci/archive/refs/heads/main.tar.gz (swap refs/heads/main for a commit SHA to pin).

  • Pick the repo: --repo owner/repository. init and migrate still need a checkout with a matching GitHub remote.

  • Test commands and toolchains live in your own workflows. Init generates no test job.

  • Interrupted? Rerun boxci init; it resumes. On an already-configured repo it reports "Already configured" and changes nothing.

  • HTTPS certificates: system certificates are used automatically. See certificate trust.

  • Existing pool? Dry run first, and read pool discovery and recovery.

Set up with a coding agent

Open your app's checkout in any agent with terminal access and paste:

Set up BoxCI for this application's repository; use https://github.com/balasivagn/boxci as the documentation reference. Install `npm install -g @balasivagn/boxci`, check `boxci --version`, and run all setup and migration commands from this application's checkout. Reuse my current GitHub/InstaBox sign-ins and show me `boxci init --dry-run` with the target repository for approval before applying. Then complete setup, migrate compatible existing Linux x64 CI jobs with `boxci migrate`, preserve existing pools, verify with `boxci doctor` and `boxci status`, and leave all workflow changes locally for my review. Do not commit, push, or open a PR.

You complete the browser sign-ins and approve the plan.

How it works

BoxCI architecture: local setup, hosted wake routing, and passive monitoring

  1. Wake. A hosted Ubuntu job wakes every pool VM for trusted events and checks their runner services. It never checks out PR code.
  2. Route. Pool ready: the build targets your dedicated self-hosted label. Otherwise, and always for fork PRs, it uses hosted ubuntu-24.04.
  3. Run. GitHub assigns the build to an idle runner. Afterwards the VMs follow InstaBox's normal idle suspension.

More: architecture and source map · interactive diagram (download and open locally)

Commands

CommandWhat it does
boxci initSet up runner, secret and pool variable; write the wake helper
boxci migrateMove existing workflow jobs onto the pool
boxci ci runDispatch a connected workflow (--workflow file.yml, --ref)
boxci statusVM and runner states, recent jobs (passive)
boxci doctorCheck account, quota, mapping, merge state, key expiry
boxci dashboardStart or reopen the background read-only dashboard
boxci dashboard status/stopCheck or stop the dashboard; runners are unaffected
boxci wakeExplicitly wake the pool
boxci pool add --count 1Add a VM, within your quota
boxci auth renewRotate the 30-day CI credential
boxci help [command]Help for boxci or one command (also --help, -h, --version)

Flags: --dry-run previews any change, --yes skips the prompt, --json gives structured output, --repo selects the repository. status, doctor and dashboard never run guest commands or wake VMs.

The dashboard keeps running after you close the terminal and doesn't restart on reboot. --no-open skips the browser, --foreground is for debugging, --port N chooses the local port (0-65535; the default, 0, picks a free port; stop a running dashboard first to change it). See dashboard operations.

Migrate existing jobs

boxci migrate --match blacksmith --dry-run
boxci migrate --match blacksmith

No flags picks jobs interactively; --jobs file.yml:job,... names them; boxci init --migrate-workflows migrates right after setup. Rerunning reuses the existing pool and helper.

The wake logic lives in .github/workflows/boxci-wake.yml. Your workflow calls it, and chosen jobs consume its output:

jobs:
  boxci-wake:
    uses: ./.github/workflows/boxci-wake.yml
    with:
      pool: ${{ vars.BOXCI_POOL }}
      runner-label: your-boxci-label
    secrets:
      api-key: ${{ secrets.BOXCI_API_KEY }}
  test:
    needs: boxci-wake
    runs-on: ${{ fromJSON(needs.boxci-wake.outputs.runner) }}

Commit the helper and its callers together. To have your agent do it, point it at skills/boxci-migrate/SKILL.md and ask, e.g. "move our Blacksmith test jobs onto BoxCI".

  • --match is a case-insensitive regular expression tested against each job's static runs-on. --jobs wins over --match. Dynamic expressions are skipped.
  • Pick Linux x64 jobs that also work on the hosted fallback. Check matrix jobs and complex needs by hand.
  • Only scheduling changes. Toolchains, services and caches stay as they are.
  • Generated inline wake blocks can be extracted. Customized ones and conflicting helper files need manual review.
  • A starter workflow left by an older release is kept as a legacy file. Remove it yourself if redundant.

Limits

  • Requirements: GitHub.com repo with admin access and Actions enabled. Paused VMs still count toward InstaBox quota. Existing GitHub and InstaBox sign-ins are reused; BoxCI bundles the InstaBox CLI and can install a checksum-verified GitHub CLI privately.
  • Use a dedicated InstaBox account for CI. The CI key can run commands on every VM in its account.
  • Capacity: one job per runner. Up to five VMs, within quota. More VMs help only with multiple jobs or a matrix. BoxCI never deletes another VM to free quota.
  • Cost and speed: no promises. BoxCI charges nothing, but InstaBox usage and hosted wake/fallback jobs bill as usual, and there is no spending cap. See InstaBox limits.
  • Credential expires every 30 days with no automatic renewal. boxci doctor warns within seven days; run boxci auth renew. If it lapses, jobs fall back to hosted Ubuntu. See renewing.
  • Queued job after wake: runner readiness doesn't prove GitHub connectivity, and fallback is chosen before assignment, so it can't rescue a job already queued. See troubleshooting.
  • Status: v0.4.1, early. POSIX shell commands only; native Linux/Windows bootstrap is unverified (validation). No automatic uninstall; see stop using BoxCI.
  • Affiliation: independent open source. Not built or endorsed by InstaBox, and not affiliated with boxci.dev.

Docs

GuideCovers
ConfigurationSign-in, local records, repo settings, pool discovery
OperationsRenewal, adding capacity, recovery, troubleshooting
ArchitectureSetup, CI and monitoring paths
ValidationWhat is tested and what isn't
Releasingnpm trusted publishing, GitHub releases
SecurityCredential scope and isolation limits

Contributing

Ideas, feature requests and collaboration are welcome: open an issue. Tests need no live credentials.

git clone https://github.com/balasivagn/boxci.git
cd boxci && npm ci
npm test
python3 -m unittest discover -s ci/tests
npm run check
npm pack --dry-run

ci/wake.py and vendor/install.sh are security-sensitive; changes need matching Python tests (see AGENTS.md). Keep scratch files in the ignored .orca-scratch/. More: developer experience · design tokens · project site.

License

Apache-2.0. Third-party notices in NOTICE and vendor/. Provider tools and vendored fonts keep their own licenses.

版本与发布记录

@balasivagn/boxci 共发布 13 个版本,首次发布于 2026/10/23;过去 12 个月发布了 13 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
0.4.1latest2026/10/2712 天前
0.4.02026/10/2513 天前
0.3.12026/10/2513 天前
0.3.02026/10/2315 天前
0.2.22026/10/2315 天前
0.2.12026/10/2315 天前

关于 @balasivagn/boxci 的常见问题

@balasivagn/boxci 是什么?

BoxCI: GitHub Actions on InstaBox. One setup, paused runners that wake for CI, optional local dashboard.

如何安装 @balasivagn/boxci?

在项目目录运行 npm install @balasivagn/boxci,或使用 pnpm add / yarn add / bun add。它还提供命令行工具 boxci,可以用 npx boxci 直接运行。

@balasivagn/boxci 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/balasivagn__boxci 是否存在。

@balasivagn/boxci 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@balasivagn/boxci 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js ^22.23.4 || >=24.22.1。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@balasivagn/boxci 可以商用吗?

@balasivagn/boxci 使用 Apache-2.0 许可。宽松许可:允许商业使用、修改和再分发,并附带明确的专利授权;分发时需保留许可与 NOTICE 文件,修改过的文件要注明改动。以上为概括,不构成法律意见,请以许可原文为准。

@balasivagn/boxci 的下载量有多少?

根据 npm 官方下载统计,@balasivagn/boxci 在 2026/10/08 – 2026/11/06 这 30 天内被下载 2,494 次,日均约 83 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@balasivagn/boxci 还在维护吗?

最新版本 0.4.1 发布于 2026/10/27(12 天前);至今共发布 13 个版本,其中过去 12 个月发布了 13 个;首次发布于 2026/10/23。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。