agentleFS
shali10shali10/awesome-agent-skills/skills/cloudflare-fullstack-ops/SKILL.md

cloudflare-fullstack-ops

Skill1 starsChanged 2 months agoMITView on GitHub

Use when deploying, configuring, or managing Cloudflare full-stack edge infrastructure including Pages, Workers, D1 SQL databases, R2 object storage, KV, and DNS routing.

  • Sends data out

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Orange Cloud (Proxied) 522 Origin Timeout: When Cloudflare proxy is active, the origin firewall (UFW/iptables) must whitelist Cloudflare IP …

    line 57

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Cloudflare Full-Stack Edge Infrastructure Operations

Overview

A complete operational guide and automation toolkit for managing Cloudflare edge resources. It covers continuous deployment on Cloudflare Pages, serverless compute via Workers, serverless relational storage with D1, S3-compatible asset hosting on R2, low-latency KV, and programmatic DNS management.

When to Use & When NOT to Use

When to Use

  • Deploying frontend SPAs / SSG sites to Cloudflare Pages with zero server maintenance.
  • Setting up Hono/TypeScript backend microservices on Cloudflare Workers.
  • Managing D1 SQLite schemas, migrations, and full-text search (FTS5).
  • Configuring R2 custom domains, CORS, and S3-compatible access tokens.
  • Automating DNS records, SSL/TLS encryption modes, and WAF security rules.

When NOT to Use

  • Traditional bare-metal or long-running Stateful TCP server orchestration.
  • Deploying complex containerized Kubernetes workloads (use standard Docker/K8s tools).

Core CLI Workflows (Wrangler & API)

# 1. Cloudflare Pages Deployment
npx wrangler pages deploy ./dist --project-name my-portal

# 2. Cloudflare D1 Database Migrations
npx wrangler d1 execute my-database --command "CREATE TABLE IF NOT EXISTS posts (id INTEGER PRIMARY KEY, title TEXT);"
npx wrangler d1 execute my-database --file=./schema.sql

# 3. Cloudflare R2 Bucket Management
npx wrangler r2 bucket create my-assets-bucket
npx wrangler r2 object put my-assets-bucket/logo.png --file=./logo.png

# 4. Programmatic DNS Record Update
curl -X POST "https://api.cloudflare.com/client/v4/zones/<ZONE_ID>/dns_records" \
  -H "X-Auth-Email: <YOUR_EMAIL>" \
  -H "X-Auth-Key: <YOUR_GLOBAL_KEY>" \
  -H "Content-Type: application/json" \
  -d '{"type":"A","name":"api.example.com","content":"198.51.100.1","proxied":true}'

Common Pitfalls

  1. Bearer Token vs Global Key Auth Mismatch: Cloudflare API endpoints differ in auth requirements; if Bearer returns Code 1000, use X-Auth-Email + X-Auth-Key headers.
  2. Orange Cloud (Proxied) 522 Origin Timeout: When Cloudflare proxy is active, the origin firewall (UFW/iptables) must whitelist Cloudflare IP ranges, or SSL mode must match (Full vs Strict).
  3. D1 Read/Write Boundaries in Workers: Remember D1 transactions are atomic per execute call; batch multi-statement queries in a single .batch([...]) call.

Verification Checklist

  • Pages project status is active and reachable over HTTPS.
  • D1 queries execute with valid response data.
  • R2 custom domain responds with valid CORS headers.
  • DNS records propagate with correct proxy status.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.