内容
# Creek
**Open-source deployment platform built on Cloudflare Workers.**
[](https://www.npmjs.com/package/creek)
[](https://www.npmjs.com/package/@solcreek/sdk)
[](LICENSE)
One command deploys your full-stack app — frontend, SSR, database, cron, queue — to 300+ Cloudflare locations worldwide. Self-host on your own account, or use Creek Cloud.
```bash
npx creek deploy
```
---
## What you get
- **One-command deploys** — auto-detects your framework, builds, and deploys
- **Built-in resources** — D1 database, R2 storage, KV cache, AI, Queues — provisioned per project
- **Cron + Queue triggers** — declare in `creek.toml`, Creek wires everything up
- **Realtime sync** — D1 writes auto-broadcast to connected clients via WebSocket
- **Per-tenant analytics** — requests, errors, latency, cron execution log
- **Agent-first** — JSON output, breadcrumb hints, MCP server, no CAPTCHAs
- **Open source** — Apache 2.0, self-host on your own Cloudflare account
---
## Zero config, one command
```bash
cd my-vite-app
npx creek deploy
# Detected: creek.toml (Vite + React + D1 + KV)
# Building...
# Deploying to edge...
# ⬡ Deployed! https://my-vite-app-myteam.bycreek.com
```
Creek detects your framework, provisions resources, builds, and deploys.
**Supported:** React · Vue · Svelte · Solid · Astro · VitePress · Hono · TanStack Start · React Router · Next.js · vinext · static HTML
**WIP:** Nuxt · SvelteKit
---
## Try it — deploy these in ~15 seconds
No signup, no config. Click a badge, watch it go live.
| | Repo | Stars | What you'll see |
|---|---|---|---|
| [](https://creek.dev/deploy/gh/satnaing/astro-paper) | [satnaing/astro-paper](https://github.com/satnaing/astro-paper) | ⭐ 4.4k | Minimal, SEO-friendly Astro blog — the most popular Astro theme |
| [](https://creek.dev/deploy/gh/withastro/docs) | [withastro/docs](https://github.com/withastro/docs) | ⭐ 1.6k | Astro's **official documentation site** |
| [](https://creek.dev/deploy/gh/vuejs/docs) | [vuejs/docs](https://github.com/vuejs/docs) | ⭐ 3.2k | Vue 3's **official documentation** — VitePress |
| [](https://creek.dev/deploy/gh/vitejs/vite/tree/main/docs) | [vitejs/vite](https://github.com/vitejs/vite) `/docs` | ⭐ 58k | Vite's **official documentation** — VitePress in a monorepo subpath |
| [](https://creek.dev/deploy/gh/sanity-io/sanity-template-astro-clean) | [sanity-io/sanity-template-astro-clean](https://github.com/sanity-io/sanity-template-astro-clean) | ⭐ 173 | Astro + Sanity starter — headless CMS pipeline |
| [](https://creek.dev/deploy/gh/danielcgilibert/blog-template) | [danielcgilibert/blog-template](https://github.com/danielcgilibert/blog-template) | ⭐ 995 | Openblog — elegant, SEO-optimised Astro blog |
First click of any repo runs a full build (~60–90s). Every click after
the first hits the build cache and deploys in ⚡ ~7s — the repo only
rebuilds when someone pushes a new commit.
**Add it to your own repo's README:**
```markdown
[](https://creek.dev/deploy/gh/YOUR-ORG/YOUR-REPO)
```
Supports GitHub `tree/{branch}/{path}` URLs for monorepos — point at a
subfolder the same way you'd link to it on GitHub.
---
## Features
### Realtime in 6 lines
WebSocket sync, optimistic updates, multi-user rooms. Zero boilerplate.
```typescript
// Server
import { db } from "creek";
import { room } from "creek/hono";
app.use("/api/*", room());
app.post("/api/todos", async (c) => {
// db.mutate() auto-broadcasts to all connected clients
await db.mutate("INSERT INTO todos (room_id, text) VALUES (?, ?)",
c.var.room, await c.req.json().then(b => b.text));
return c.json({ ok: true });
});
```
```tsx
// Client
import { LiveRoom, useLiveQuery } from "creek/react";
function App() {
const { data: todos, mutate } = useLiveQuery("/api/todos");
// Auto-refetches when data changes. Optimistic updates with auto-rollback.
}
```
### Cron + Queue triggers
```toml
# creek.toml
[project]
name = "my-app"
[resources]
database = true
[triggers]
cron = ["0 */6 * * *"] # Every 6 hours
queue = true # Auto-provisions a CF Queue
```
```typescript
// worker/index.ts
import { db, queue } from "creek";
export default {
async fetch(request, env) {
await queue.send({ type: "process", id: "123" });
return new Response("queued");
},
async scheduled(event, env, ctx) {
// Runs every 6 hours
await db.prepare("DELETE FROM stale WHERE created < ?").bind(Date.now() - 86400000).run();
},
async queue(batch, env, ctx) {
for (const message of batch.messages) {
// Process message
}
},
};
```
### Per-tenant analytics
Built-in dashboard shows requests, errors, CPU latency (p50/p99) for the last 24h / 7d / 30d. Cron execution log included.
### Built-in resources
```toml
[resources]
database = true # D1 (SQLite at the edge)
storage = true # R2 (object storage, zero egress)
cache = true # KV (key-value)
ai = true # Workers AI
```
Creek provisions per-tenant resources via the Cloudflare API. Each project gets its own isolated D1 database, R2 bucket, KV namespace.
---
## Built for AI agents
```bash
# JSON output auto-enabled in non-TTY / CI
npx creek deploy --sandbox --json
```
```json
{
"ok": true,
"url": "https://my-app-myteam.bycreek.com",
"deploymentId": "a1b2c3d4-...",
"cron": ["0 */6 * * *"],
"breadcrumbs": [
{ "command": "creek status", "description": "Check deployment status" }
]
}
```
- **No CAPTCHAs** — [Agent Challenge](https://creek.dev/docs/api#agent-challenge) protocol issues verified agent tokens (60/hr vs 10/hr)
- **Breadcrumb hints** in error responses guide agents to next steps
- **MCP server** at `mcp.creek.dev` (in development) — any AI agent can deploy with a single tool call
---
## Open source
Apache 2.0 licensed. The entire platform is open source — CLI, control plane, dashboard, runtime, sandbox, dispatch worker.
Self-host on your own Cloudflare account, or use [Creek Cloud](https://creek.dev) (managed).
```bash
git clone https://github.com/solcreek/creek.git
cd creek && pnpm install
# Copy wrangler.*.example → wrangler.*, fill in your CF account
pnpm --filter @solcreek/control-plane deploy
```
Enterprise governance features (SSO, approval workflows, policy engine) will be available under `/ee` in a separate license.
---
## CLI Reference
```
creek deploy [dir] Deploy project or directory
creek deploy --template landing Start from a ready-made Vite + React template
creek deploy --dry-run Show the deploy plan without executing
creek deploy --json Output structured JSON (auto in CI)
creek deploy --skip-build Deploy without running build step
creek dev Local dev server with D1/KV/R2 simulation
creek status Project status, triggers, deployment info
creek deployments List deployment history
creek logs Read recent log entries (R2 archive)
creek logs --follow Live tail via WebSocket until Ctrl+C
creek logs --deployment <id> --outcome exception Filter by deploy / outcome / branch / level / search
creek rollback Rollback to a previous deployment
creek env set <key> <val> Set an environment variable
creek env ls List environment variables
creek domains add <host> Add a custom domain
creek login Authenticate with Creek
creek init Create creek.toml configuration
creek claim <sandboxId> Convert sandbox preview to permanent project
```
---
## How it works
```
CLI / API / MCP
|
+------------+------------+
| |
Sandbox API Control Plane
(no auth, 60min) (auth, permanent)
| |
+------------+------------+
|
Workers for Platforms
(dispatch namespace)
|
+--------+--------+
| | |
Worker Static D1/R2/KV/Queue
Script Assets (per-tenant)
|
Cloudflare Edge
(300+ locations)
```
**Sandbox path:** `creek deploy` / `creek deploy --template <name>` → Sandbox API → live URL (60 min, no auth)
**Production path:** `creek deploy` → Control Plane → permanent URL + custom domain
---
## Project structure
```
creek/
apps/
dashboard/ Vite + React + TanStack Router (app.creek.dev)
www/ Next.js marketing site via adapter-creek (creek.dev)
packages/
cli/ CLI — npm: creek
sdk/ TypeScript SDK — npm: @solcreek/sdk
runtime/ creek runtime for deployed apps — npm: @solcreek/runtime
deploy-core/ Shared WfP deployment logic
control-plane/ Hono API + Better Auth + D1 (api.creek.dev)
sandbox-api/ Public sandbox deploy API
sandbox-dispatch/ Sandbox routing + banner injection
dispatch-worker/ Production tenant routing
realtime-worker/ WebSocket via Durable Objects
remote-builder/ CF Containers remote build orchestrator
build-container/ Build environment Docker image
ui/ Shared UI (shadcn v4 + Base UI)
create-creek-app/ Template scaffolder — npm: create-creek-app
mcp-server/ MCP server (mcp.creek.dev)
```
---
## Tech stack
- **Runtime:** Cloudflare Workers
- **Framework:** Hono (API), Vite + React (dashboard), Next.js (www)
- **Database:** Cloudflare D1 (SQLite) + Drizzle ORM
- **Storage:** Cloudflare R2
- **Queue:** Cloudflare Queues
- **Auth:** Better Auth (GitHub, Google, email/password, API keys)
- **Multi-tenancy:** Workers for Platforms (dispatch namespaces)
- **Monorepo:** pnpm workspaces + Turborepo
- **Testing:** Vitest (790+ tests)
---
## Self-hosting
Creek is designed to run entirely on a single Cloudflare account.
**Prerequisites**
- Cloudflare account with Workers for Platforms enabled
- Node.js >= 18, pnpm >= 9
```bash
git clone https://github.com/solcreek/creek.git
cd creek
pnpm install
# Configure: copy each wrangler.*.example to wrangler.* and fill in
# your Cloudflare account ID, dispatch namespace, and resource bindings
# Deploy workers
pnpm --filter @solcreek/control-plane deploy
pnpm --filter @solcreek/sandbox-api deploy
pnpm --filter @solcreek/sandbox-dispatch deploy
pnpm --filter @solcreek/dispatch-worker deploy
```
See [Self-Hosting Guide](https://creek.dev/docs/self-hosting) for detailed instructions.
---
## Development
```bash
pnpm install
pnpm test # Run all tests (790+)
pnpm typecheck # TypeScript checks across all packages
pnpm dev # Start all dev servers
```
---
## Next.js Adapter
Creek ships its own Next.js adapter — **[`@solcreek/adapter-creek`](https://github.com/solcreek/adapter-creek)** — purpose-built for Cloudflare Workers for Platforms.
```bash
npm install @solcreek/adapter-creek
creek deploy
```
The CLI auto-detects Next.js >= 16.2.3 and invokes the adapter. No config needed.
**What it does differently from generic adapters:**
- **Streaming SSR** via `TransformStream` — compatible with Workers' request lifecycle (no `node:http` server dependency)
- **Embedded manifests** — all Next.js route/build/prerender manifests are inlined into the worker bundle via a custom `fs` shim, so no filesystem reads at runtime
- **Node.js API shims** — `http`, `https`, `net`, `inspector`, `fs`, `vm`, `process` EventEmitter stubs — purpose-built for the APIs Next.js actually touches, not generic polyfills
- **Turbopack runtime patching** — replaces dynamic `R.c()` chunk loading with a static `requireChunk()` switch for Workers' no-filesystem constraint
- **Zero config** — the adapter hooks into Next.js's `onBuildComplete` lifecycle and produces a `.creek/adapter-output/` bundle the CLI uploads directly
**Dogfooding:** [creek.dev](https://creek.dev) is a Next.js app — its source lives in [`apps/www`](apps/www) in this repo — and it's deployed on Creek's own infrastructure via `creek deploy --yes`. Same platform, same adapter, same pipeline that every other Creek user gets. If the adapter breaks, our own marketing site breaks first.
## Ecosystem
- **[Awesome Creek](https://github.com/solcreek/awesome-creek)** — Curated list of templates, integrations, guides, and community projects. Submissions welcome.
- **[Templates Gallery](https://templates.creek.dev)** — Live previews of official starter templates.
---
## Contributing
We welcome contributions. Please see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
- **Issues:** [github.com/solcreek/creek/issues](https://github.com/solcreek/creek/issues)
- **Discussions:** [github.com/solcreek/creek/discussions](https://github.com/solcreek/creek/discussions)
---
## License
Apache 2.0 — see [LICENSE](LICENSE).
---
**[creek.dev](https://creek.dev)** · **[Docs](https://creek.dev/docs)** · **[Templates](https://templates.creek.dev)** · **[Discord](https://discord.gg/creek)**
Built by [SolCreek](https://creek.dev).
连接信息
猜你喜欢
rea
用于编码代理的逆向工程:一个 CLI 和 MCP 服务器,用于检查任何应用程序,了解其功能,并按照您的方式构建它们。
everything-claude-code
完整的 Claude Code 配置集合 - agents、skills、hooks、commands、rules、MCPs。来自 Anthropic...
MarkItDown MCP
MarkItDown-MCP是一个轻量级服务器,用于将URI转换为Markdown。
cc-switch
跨平台的Claude Code、Codex和Gemini CLI一体化助手。
Agent-Reach
赋予你的AI Agent观察整个互联网的眼睛。读取并搜索...
servers
# 模型上下文协议服务器