Pular para o conteúdo

Deployment Overview

RedeCasas uses a multi-layer deployment strategy:

  1. Static site — uploaded to Cloudflare R2 via incremental smart deploy
  2. Workers — deployed independently via Wrangler
  3. Database — D1 migrations applied via Wrangler

Deploy Targets

ComponentTargetTool
Static HTMLCloudflare R2rclone + smart deploy
Auth WorkerCloudflare Workerswrangler deploy
Billing WorkerCloudflare Workerswrangler deploy
Listings WorkerCloudflare Workerswrangler deploy
Chat WorkerCloudflare Workerswrangler deploy
D1 SchemaCloudflare D1wrangler d1 execute

Deploy Order

  1. Apply D1 migrations (if schema changed)
  2. Deploy Workers (auth → billing → listings → chat)
  3. Build site (go run . build-pages)
  4. Smart deploy to R2
  5. Verify with QA suite

Partial / Single-page Deploys

You do not need a full site build to update individual page groups. For example, auth pages and other single pages can be deployed explicitly:

Terminal window
cd site
./deploy-single.sh

Or manually:

Terminal window
cd site
go run . build-page single
go run . smart-deploy --single

See Single Page Deploys for the full workflow.