Pin the Firestore deploy target to the c2-server database
Build & Deploy / Build & push images (push) Successful in 4m4s
Build & Deploy / Deploy to VM (push) Successful in 2m8s
Build & Deploy / Report a failed deploy (push) Skipped

firebase.json declared rules and indexes with no database key, so the CLI
deploys them to (default). This project does not use (default) -- c2-core
reads FIRESTORE_DATABASE and the frontend reads NEXT_PUBLIC_FIRESTORE_DATABASE,
both c2-server in production, and the index-required errors the browser prints
name /databases/c2-server/ outright. A deploy without this key reports success
and changes nothing the app can see, which is a bad way to find out.

Refs server-26#13.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Logan Cusano
2026-08-23 02:37:43 -04:00
co-authored by Claude Opus 5
parent be79499635
commit a278e2215a
+2
View File
@@ -1,6 +1,8 @@
{ {
"//": "Deploy target for firestore.rules / firestore.indexes.json only — this is not a Firebase Hosting project config. Run from this directory: firebase deploy --only firestore:rules,firestore:indexes --project <project-id>. No project id is pinned here deliberately (see [[self-hosted-infra-pointers]] for where that value lives) — pass --project explicitly or run `firebase use <project-id>` once first.", "//": "Deploy target for firestore.rules / firestore.indexes.json only — this is not a Firebase Hosting project config. Run from this directory: firebase deploy --only firestore:rules,firestore:indexes --project <project-id>. No project id is pinned here deliberately (see [[self-hosted-infra-pointers]] for where that value lives) — pass --project explicitly or run `firebase use <project-id>` once first.",
"firestore": { "firestore": {
"//": "database MUST be pinned. This project does not use the (default) Firestore database — drb-c2-core reads FIRESTORE_DATABASE and drb-frontend reads NEXT_PUBLIC_FIRESTORE_DATABASE, both 'c2-server' in production, and the index-required errors the browser prints name /databases/c2-server/ explicitly. Without this key the CLI deploys rules and indexes to (default), reports success, and changes nothing the app can see.",
"database": "c2-server",
"rules": "firestore.rules", "rules": "firestore.rules",
"indexes": "firestore.indexes.json" "indexes": "firestore.indexes.json"
} }