Skip to content

Instantly share code, notes, and snippets.

@Jimgerneer
Last active March 17, 2026 07:20
Show Gist options
  • Select an option

  • Save Jimgerneer/216bd7ae3d3ef1ece2c464e926f1585f to your computer and use it in GitHub Desktop.

Select an option

Save Jimgerneer/216bd7ae3d3ef1ece2c464e926f1585f to your computer and use it in GitHub Desktop.

Domain Migration: app.bzzr.combzzr.com

Current → Target

Environment Current Target
Production app.bzzr.com bzzr.com
Staging app.staging.bzzr.com staging.bzzr.com
Webflow bzzr.com decommissioned

Phase 1: Preparation (no downtime, can be done anytime)

  • Firebase Console → bzzr-staging → Auth → Authorized domains → add staging.bzzr.com
  • Firebase Console → bzzr-production → Auth → Authorized domains → add bzzr.com
  • Firebase Console → App Hosting → Staging backend → Custom domains → add staging.bzzr.com (note the DNS records)
  • Firebase Console → App Hosting → Production backend → Custom domains → add bzzr.com (note the DNS records)
  • Lower DNS TTL on bzzr.com to 60s (do this 24–48 hours before Phase 4)

Gate check: All Firebase Auth domains and App Hosting custom domains are configured. DNS records are noted but NOT updated yet.


Phase 2: Code Changes (deploy before DNS cutover)

bzzr-web:

  • Update apphosting.staging.yamlNEXT_PUBLIC_API_DOMAIN: https://app.staging.bzzr.comhttps://staging.bzzr.com
  • Update apphosting.production.yamlNEXT_PUBLIC_API_DOMAIN: https://app.bzzr.comhttps://bzzr.com
  • Deploy staging
  • Deploy production

bzzr-flutter (sidecast):

  • Update packages/bzzr_shared/lib/providers/networking/bzzr_app_base_url_provider.dart:
    • Staging: https://app.staging.bzzr.comhttps://staging.bzzr.com
    • Production: https://app.bzzr.comhttps://bzzr.com
  • Deploy/release sidecast app

Backend:

  • Add https://staging.bzzr.com to CORS allowed origins on api.staging.bzzr.com
  • Add https://bzzr.com to CORS allowed origins on api.bzzr.com

Third-party services:

  • OAuth providers (Google, Apple, etc.) — add new domains to authorized redirect URIs
  • GetStream.io — update any webhook URLs or allowed origins
  • Mux — update any webhook/domain configs
  • Cloudflare — update any origin rules if applicable

Gate check: All codebases deployed. Backend CORS updated. Third-party services configured. Old domains still work — nothing is broken yet.


Phase 3: Staging DNS Cutover (dry run)

  • Update DNS for staging.bzzr.com → Firebase App Hosting (using records from Phase 1)
  • Verify DNS propagation
  • Test: sign in / sign up flow
  • Test: share links / copy link generate correct staging.bzzr.com URLs
  • Test: public share pages load
  • Test: API calls succeed (no CORS errors in console)
  • Test: sidecast app authenticates successfully

Gate check: Staging is fully functional on staging.bzzr.com. No auth, CORS, or routing issues.


Phase 4: Production DNS Cutover

  • Confirm DNS TTL on bzzr.com is low (60s)
  • Update DNS for bzzr.com → Firebase App Hosting (swap from Webflow)
  • Verify DNS propagation
  • Test: sign in / sign up flow
  • Test: share links / copy link generate correct bzzr.com URLs
  • Test: public share pages load
  • Test: API calls succeed (no CORS errors in console)
  • Test: sidecast app authenticates successfully
  • Test: app.bzzr.com still resolves (keep pointed at Firebase for redirects)

Gate check: Production is fully functional on bzzr.com.


Phase 5: Cleanup

  • Set up permanent redirects app.bzzr.combzzr.com (Next.js config or Firebase)
  • Set up permanent redirects app.staging.bzzr.comstaging.bzzr.com
  • Remove app.bzzr.com and app.staging.bzzr.com from Firebase Auth authorized domains
  • Restore DNS TTL on bzzr.com to normal (e.g. 3600s)
  • Decommission Webflow site

Gate check: Old URLs redirect cleanly. No references to app.bzzr.com remain in active config. Webflow is shut down.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment