Spawner

io.github.Flosk6由 GitHub 账号 Flosk6 发布v2.2.1更新于 Oct 24, 2026

Preview environments on your self-hosted Spawner server: a copy of your app for each git branch

概览

AI 生成的概览

面向自建 Spawner 服务器的 MCP 服务器,让助手按分支创建、查看、在其中执行命令并删除预览环境。

可以做什么
  • 从工作区为当前分支创建和更新预览环境,包含未提交的改动
  • 查看环境状态、列出环境、读取资源统计并获取环境地址
  • 读取环境日志,可只筛选错误行
  • 在环境的服务中执行命令
  • 生成无需账号即可访问的分享链接,以及删除环境
适用场景
适合团队自建 Spawner 服务器,并希望编码助手在不离开编辑器或对话的情况下为分支启动、排查和清理预览环境。
运行要求
需要 Node.js 20 或更高版本并全局安装 spawner-cli,以及可访问的自建 Spawner 服务器。可交互执行 spawner login 登录,或在 CI 与容器中设置 SPAWNER_URL 和 SPAWNER_TOKEN。首次创建环境前,管理员需在控制台添加项目。
安装前请注意
该服务器以 CLI 的登录身份和权限行事。spawner_exec 会在环境服务中执行任意命令,spawner_down 会删除环境;两者都标记为破坏性操作,客户端是否先行确认取决于其权限设置。SPAWNER_TOKEN 是拥有该账号权限的个人 API 令牌。分享链接会让无账号的人访问环境。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Spawner,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

spawner-cli

The command line and MCP server of Spawner. Spawner is an open source, self-hosted preview environment manager: a copy of your app for each git branch, on your own server, with its own URLs, database and logs, for teams and their coding agents.

With spawner, developers and coding agents create, update and delete environments from a worktree, uncommitted changes included, run commands in them and read their logs.

Install

bash
npm install -g spawner-cli

It needs Node.js 20 or later, and a Spawner server: install one with a single command. Every server also serves the CLI of its own version at /api/v1/cli/spawner.

Log in

bash
spawner login https://spawner.preview.example.com

Type the code it shows in the dashboard and approve the login: the CLI stores a personal token. In CI or a container, SPAWNER_URL and SPAWNER_TOKEN replace the login.

Commands

bash
# write .spawner/, and offer to add the instructions for coding agentsspawner init
# the environment of the current branch, from this worktreespawner up --wait
# run a command in a servicespawner exec feat-login db -- psql -U app -c "select * from users"
# only the error lines, stack traces kept wholespawner logs feat-login api --errors
# a link for someone without an accountspawner share feat-login
spawner down feat-login

Before the first spawner up of a project, an admin adds the project in the dashboard (Projects, New project). The other commands: status, ls, stats, capacity, url, shell, stop, start, sleep, wake, extend, token, whoami and logout.

Commands print JSON with --json and exit with stable codes: 4 when the environment failed, 6 when the quota or the server's capacity is reached, 7 when .spawner/ was refused.

MCP server

spawner mcp is an MCP server on stdio, with the login and the rights of the CLI. In Claude Code:

bash
claude mcp add spawner -- spawner mcp

In a project's .mcp.json, or Cursor's .cursor/mcp.json:

json
{  "mcpServers": {    "spawner": { "command": "spawner", "args": ["mcp"] }  }}

It has nine tools: spawner_up, spawner_status, spawner_list, spawner_logs, spawner_exec, spawner_stats, spawner_url, spawner_share and spawner_down. spawner_exec and spawner_down are marked destructive: whether a client asks before running them depends on the client and its permission settings.

Documentation

Source: github.com/Flosk6/Spawner. License: Apache-2.0.

来源:apps/cli/README.md,提交 b9c01c6

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

2
  1. v2.2.1最新Oct 11, 2026
  2. v2.2.0Oct 10, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分