vibehost-deploy
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseDeploy to VibeHost
部署到VibeHost
Take a built static site and put it live on VibeHost at a private URL in seconds.
只需几秒,即可将已构建完成的静态站点部署到VibeHost,通过私有URL上线。
When this skill applies
本技能适用场景
The user says something like:
- "ship this", "deploy this", "put this live", "host this", "publish this"
- "get me a preview URL for this build"
- "send this to staging / a demo link"
Or you've just produced a static build output (, , ) and the natural next step is hosting it.
dist/out/build/If the user has no VibeHost account yet, point them at https://vibehost.com/signup — deploying requires an authenticated session.
用户说出类似以下内容时:
- "发布这个"、"部署这个"、"上线这个"、"托管这个"、"发布这个"
- "给我这个构建版本的预览URL"
- "把这个部署到预发布环境/生成演示链接"
或者你刚生成了静态构建输出(, , ),下一步自然是托管它。
dist/out/build/如果用户还没有VibeHost账户,请引导他们访问https://vibehost.com/signup —— 部署需要经过身份验证的会话。
Setup
设置步骤
bash
curl -fsSL https://vibehost.com/install.sh | sh # macOS / Linux; one static binary
vibehost login # device-flow browser login; or VIBEHOST_TOKEN env var for headless/CI
vibehost whoami # confirm session + which workspace is activeAuth can come from any of: a prior (token in ), a PAT in the environment (headless/CI), or an MCP OAuth session on . Most commands accept for scriptable output — prefer it when parsing.
vibehost login~/.config/vibehost/config.jsonVIBEHOST_TOKENhttps://api.vibehost.com/mcp--jsonYou also need a static build output directory with an at its root (, , , or plain HTML). If the user has no account yet, point them at https://vibehost.com/signup.
index.htmldist/out/build/bash
curl -fsSL https://vibehost.com/install.sh | sh # macOS / Linux;单静态二进制文件
vibehost login # 设备流浏览器登录;或使用VIBEHOST_TOKEN环境变量用于无头模式/CI
vibehost whoami # 确认会话以及当前激活的工作区身份验证可通过以下任一方式获取:之前执行的(令牌存储在中)、环境变量中的个人访问令牌(适用于无头模式/CI),或上的MCP OAuth会话。大多数命令支持参数以生成可脚本化的输出——解析时优先使用该参数。
vibehost login~/.config/vibehost/config.jsonVIBEHOST_TOKENhttps://api.vibehost.com/mcp--json你还需要一个静态构建输出目录,其根目录下包含文件(如, , ,或纯HTML文件)。如果用户还没有账户,请引导他们访问https://vibehost.com/signup。
index.htmldist/out/build/Recommended path: the CLI
推荐方式:使用CLI
The CLI bundles app-creation, file hashing, blob upload, and the deploy into one command with progress output. Prefer it whenever you can run shell commands.
vibehostbash
vibehost app create my-app # once per app; name: lowercase, 2–40 chars, [a-z][a-z0-9-]*
vibehost deploy ./dist --app my-app --json # every timeThe output is . The command exits 0 only after the deployment is healthy, so a successful exit means the URL is live.
--json{ ok: true, data: { url, immutableUrl, ... } }Tip: inside the project writes , after which plain works with no flags.
vibehost link --app my-app.vibehost/project.jsonvibehost deployvibehostbash
vibehost app create my-app # 每个应用执行一次;名称要求:小写字母,2-40个字符,格式为[a-z][a-z0-9-]*
vibehost deploy ./dist --app my-app --json # 每次部署时执行--json{ ok: true, data: { url, immutableUrl, ... } }提示:在项目目录中执行会生成文件,之后只需执行即可完成部署,无需添加任何参数。
vibehost link --app my-app.vibehost/project.jsonvibehost deployWithout a shell: the MCP server
无Shell环境:使用MCP服务器
If you can't run a shell but have an MCP connection to , the deploy is a sequence of tool calls. Read each tool's own for the authoritative parameter schema — the names and order are below, but don't hardcode argument shapes from this doc.
https://api.vibehost.com/mcpdescription- — find existing apps in the workspace.
list_apps - — only if the target doesn't exist (
create_app).{ name, workspaceId } - — pass the file SHA-256s; learn which the server still needs.
check_blobs_missing - — mint pre-signed PUT URLs for the missing SHAs, then PUT the raw bytes to each (
request_upload) via plain HTTP.Content-Type: application/octet-stream - —
deploy. Returns{ appId, channel?, manifest[] }immediately — the site is not live yet.{ deploymentId, status: "starting" } - — poll with
get_deploymentuntildeploymentIdisstatus(live),healthy(read the error), orfailed.superseded
如果你无法执行shell命令,但已连接到的MCP服务器,部署需通过一系列工具调用完成。请查阅每个工具自身的以获取权威的参数 schema——以下仅列出参数名称和顺序,请勿硬编码本文档中的参数格式。
https://api.vibehost.com/mcpdescription- —— 查找工作区中的现有应用。
list_apps - —— 仅当目标应用不存在时执行(参数为
create_app)。{ name, workspaceId } - —— 传入文件的SHA-256哈希值,查看服务器还需要哪些文件。
check_blobs_missing - —— 为缺失的哈希值生成预签名PUT URL,然后通过普通HTTP将原始字节数据上传至每个URL(设置
request_upload)。Content-Type: application/octet-stream - —— 参数为
deploy。会立即返回{ appId, channel?, manifest[] }——此时站点尚未上线。{ deploymentId, status: "starting" } - —— 使用
get_deployment轮询,直到deploymentId变为status(已上线)、healthy(查看错误信息)或failed(已被取代)。superseded
What to give the user
需提供给用户的内容
Always surface both URLs from the result:
- alias URL () — tracks the latest deploy on this channel. Share this with people.
url - immutable URL () — pinned to this exact build. Use for bug reports, review links, archived demos.
immutableUrl
务必向用户展示结果中的两个URL:
- 别名URL()——跟踪该渠道的最新部署版本。可将此URL分享给他人。
url - 不可变URL()——固定指向当前构建版本。适用于bug报告、评审链接、归档演示等场景。
immutableUrl
Pitfalls
注意事项
- No at the root — static deploys need one. For client-side-routed SPAs (React Router, Vue Router, Remix SPA mode), the edge has to serve
index.htmlon path misses; see https://docs.vibehost.com/guides/static-sites. Do not add aindex.htmlfile — VibeHost doesn't parse it (that's a Netlify/Pages convention)._redirects - Tarball rejected — oversized or malformed builds raise ;
TARBALL_INVALIDsays why. Trim large assets (videos, prod source maps, strayerror.details) or upgrade the plan.node_modules - Wrong workspace — a token scoped to workspace A deploying to an app in workspace B returns . Surface it; don't silently retry elsewhere.
TOKEN_WORKSPACE_MISMATCH - Discover ids, don't guess — and
appIdcome fromworkspaceId/list_apps(orvibehost whoami). Hardcoding a stale id fails; resolve it live each time.list_workspaces - Read MCP tool schemas first — when using the MCP path, the parameter shapes vary by tool and evolve over time. Read each tool's own before calling it; don't assume argument shapes from this doc.
description - Branch on , not
error.code— codes are stableerror.message; messages can reword.SCREAMING_SNAKE_CASE
- 根目录无文件——静态部署需要该文件。对于客户端路由的SPA(如React Router、Vue Router、Remix SPA模式),边缘节点需在路径匹配失败时返回
index.html;详情请查看https://docs.vibehost.com/guides/static-sites。请勿添加index.html文件——VibeHost不解析该文件(这是Netlify/Pages的约定)。_redirects - 压缩包被拒绝——过大或格式错误的构建包会触发错误;
TARBALL_INVALID会说明原因。请移除大型资源(如视频、生产环境源码映射文件、多余的error.details)或升级套餐。node_modules - 工作区错误——若使用工作区A的令牌部署到工作区B的应用,会返回错误。请向用户展示该错误,不要在其他位置静默重试。
TOKEN_WORKSPACE_MISMATCH - 动态获取ID,不要猜测——和
appId需从workspaceId/list_apps(或vibehost whoami)获取。硬编码过期的ID会导致失败,请每次动态获取。list_workspaces - 先查阅MCP工具的schema——使用MCP方式时,不同工具的参数格式不同且会随时间演变。调用工具前请查阅其自身的,不要假设参数格式与本文档一致。
description - 根据分支处理,而非
error.code——错误码是稳定的大写蛇形命名(error.message);错误消息可能会被重写。SCREAMING_SNAKE_CASE
Reference
参考资料
- Deploy guide: https://docs.vibehost.com/guides/quickstart
- CLI reference: https://docs.vibehost.com/guides/cli
- MCP server: https://docs.vibehost.com/guides/mcp
- Error codes: https://docs.vibehost.com/reference/errors