Implementation: What branch name should wrangler send to Cloudflare for prod...
Documentation for Sessions
⚙️ Implementation: What branch name should wrangler send to Cloudflare for prod...
Date: 2026-01-28
Time: 18:48:40 UTC
Session: editor2-73.5
Agent: orchestrator
Confidence: 100%
Status: ✅ Documented
📋 Decision Context
Question:
What branch name should wrangler send to Cloudflare for production deployments?
Task: Fix Cloudflare deploying to Preview instead of Production
🎯 Decision Made
Chosen:
The branch name in wrangler --branch flag MUST match Cloudflare's production branch setting exactly
Options Considered:
- --branch=main (traditional)
- --branch=deploy/docs (match CF setting)
- --branch=production (semantic)
💭 Reasoning
Critical discovery: If Cloudflare production branch is set to "deploy/docs", wrangler must send --branch=deploy/docs. Sending --branch=main (even if logical) results in Preview deployment, not Production. Cloudflare uses exact string matching between the wrangler branch parameter and its production branch setting to determine deployment environment.
📁 Files Involved
.github/workflows/deploy-docs.yml
🔗 Related
- Decision ID:
dev_1769626116788_lj0a8xm - Session: 73
- Workspace: editor2
Auto-generated by MCP Smart Consolidation