devops/deploy-cloudflare

devops/deploy-cloudflare is a skill for Claude Code from echoVic/boss-skill. It costs 42 tokens per session (1,778 once invoked), scanned A, original, MIT.

A deployment guide for Cloudflare Pages and Workers using the Wrangler command-line tool. Pages hosts frontend and static sites, while Workers runs serverless code and APIs at Cloudflare's edge locations.

In plain words
What is it for?
Use it to publish frontend sites, deploy serverless APIs or webhooks, and deploy Next.js applications with Cloudflare's supported setup.
Why use it?
It helps you choose the right Cloudflare deployment model and configure builds, environments, and global serverless code for different application types.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter. Also seen: agent in frontmatter.

Part of the boss plugin — 39 skills, 10 commands, 9 agents, 8 hooks shipped together

Good fit Use it to publish frontend sites, deploy serverless APIs or webhooks, and deploy Next.js applications with Cloudflare's supported setup.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/echovic/boss-skill/deploy-cloudflare
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add echoVic/boss-skill --skill deploy-cloudflare
Clone the repo
git clone --depth 1 https://github.com/echoVic/boss-skill

Made for: Claude Code.

Or install boss, the plugin that ships this one along with the rest of its 39 skills, 10 commands, 9 agents, 8 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for devops/deploy-cloudflare

README.md
[![agentmods](https://agentmods.dev/badge/skills/echovic/boss-skill/deploy-cloudflare/github.svg)](https://agentmods.dev/skills/echovic/boss-skill/deploy-cloudflare)
Your own site
<a href="https://agentmods.dev/skills/echovic/boss-skill/deploy-cloudflare"><img src="https://agentmods.dev/badge/skills/echovic/boss-skill/deploy-cloudflare/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for devops/deploy-cloudflare

Your own site · 80×15
<a href="https://agentmods.dev/skills/echovic/boss-skill/deploy-cloudflare"><img src="https://agentmods.dev/badge/skills/echovic/boss-skill/deploy-cloudflare.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 42 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,778 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00042 $0.01778
Opus 5.5 $0.00017 $0.00711
Sonnet 5.5 $0.00008 $0.00356
Haiku 4.5 $0.00004 $0.00178

Measured today against content hash 93ada7cd44f0, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

devops/deploy-cloudflare scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skill/skills/devops/deploy-cloudflare/SKILL.md · 262 lines

How it starts

The opening of the file, as written. The whole thing — 262 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Cloudflare 部署

适用场景

  • Cloudflare Pages:前端应用(Next.js、React、Vue、SvelteKit、静态站点)
  • Cloudflare Workers:边缘 Serverless 函数、API、Webhooks
  • 需要全球边缘网络低延迟的场景
  • 对冷启动和全球分发有要求的应用

前置条件

  1. 安装 Wrangler CLI:npm i -g wrangler
  2. 登录 Cloudflare:npx wrangler login(需要用户交互完成授权)
  3. 验证登录状态:npx wrangler whoami

部署模式选择

项目类型 部署模式 命令
前端应用 / SPA Cloudflare Pages wrangler pages deploy
静态站点 Cloudflare Pages wrangler pages deploy
Serverless API / 边缘函数 Workers wrangler deploy
Next.js SSR Pages (Next adapter) wrangler pages deploy

一、Cloudflare Pages 部署

1. 构建项目

npm run build
# 产物目录通常为 dist/、build/ 或 .next/

2. 首次部署

# 部署静态产物到 Cloudflare Pages
npx wrangler pages deploy dist --project-name=my-app

首次部署输出示例:

✨ Compiled Worker successfully
🌍  Uploading... (20.4 MB)
✨ Deployment complete! Take a peek over at https://my-app.pages.dev

3. 配置 wrangler.toml(Pages 项目)

Pages 项目可以使用 wrangler.toml 或命令行参数管理配置:

name = "my-app"
compatibility_date = "2024-01-01"
pages_build_output_dir = "dist"

[env.production]
name = "my-app"

[env.staging]
name = "my-app-staging"

4. 环境变量

# 设置环境变量(Pages)
npx wrangler pages secret put DATABASE_URL

# 列出 secrets
npx wrangler pages secret list

# 删除 secret
npx wrangler pages secret delete DATABASE_URL

5. 自定义域名

# 绑定自定义域名到 Pages 项目
npx wrangler pages domain add example.com --project-name=my-app

二、Cloudflare Workers 部署

1. wrangler.toml 配置

name = "my-worker"
main = "src/index.ts"
compatibility_date = "2024-01-01"
compatibility_flags = ["nodejs_compat"]

# 路由绑定
routes = [
  { pattern = "api.example.com/*", zone_name = "example.com" }
]

# KV 命名空间绑定
[[kv_namespaces]]
binding = "MY_KV"
id = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

# R2 存储桶绑定
[[r2_buckets]]
binding = "MY_BUCKET"
bucket_name = "my-bucket"

# D1 数据库绑定
[[d1_databases]]
binding = "DB"
database_name = "my-db"
database_id = "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Read the full file on GitHub · 262 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today First seen · 262 lines · 42 tokens per session scan A 93ada7cd44f0

Subscribe to this mod's changes

devops/deploy-cloudflare is a skill published in the GitHub repository echoVic/boss-skill (544 stars, last pushed today), licensed MIT. It adds 42 tokens to every session and 1,778 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-28.

Related

Other skills, from other repositories

linkerd-patterns

Implement Linkerd service mesh patterns for lightweight, security-focused service mesh deployments. Use when setting up Linkerd, configuring traffic policies, or implementing zero-trust networking with minimal overhead.

wshobson/agents · 41 tokens

cost-optimization

Optimize cloud costs across AWS, Azure, GCP, and OCI through resource rightsizing, tagging strategies, reserved instances, and spending analysis. Use when reducing cloud expenses, analyzing infrastructure costs, or implementing cost governance policies.

wshobson/agents · 48 tokens

istio-traffic-management

Configure Istio traffic management including routing, load balancing, circuit breakers, and canary deployments. Use when implementing service mesh traffic policies, progressive delivery, or resilience patterns.

wshobson/agents · 40 tokens

convex-ship

Publish the current Convex app to a live .convex.app URL (deploy backend + upload web build).

openclaw/clawhub · 27 tokens

dokploy-deploy

This skill should be used when user asks to "deploy with Dokploy", "use Dokploy Cloud", "manage self-hosted Dokploy", "deploy Docker Compose on Dokploy", "manage Dokploy databases", "configure Dokploy domains", or "look up Dokploy CLI commands".

fcakyon/claude-codex-settings · 63 tokens

openship-config

This skill should be used when the user asks to "create openship.json", "configure an OpenShip deployment", "make a repo deployable on OpenShip", or fix "openship config validate" errors.

fcakyon/claude-codex-settings · 47 tokens