[email protected]
thereomone
git branch
firestore.rules
/common/envs
/common/envs/constants.ts
/functions/.env
with NEXT_PUBLIC_FIREBASE_ENV=SUPERSYNC
[ ] $ firebase use mantic-markets
to select the main project
[ ] firebase firestore:indexes > firestore.indexes.json
to copy indexes
[ ] Copy secrets (Mailgun & Stripe keys) from main project
firebase functions:secrets:access MAILGUN_KEY
firebase functions:secrets:access STRIPE_APIKEY
firebase functions:secrets:access STRIPE_WEBHOOKSECRET
[ ] $ firebase use <PROJECT_ID>
to select the new Firebase project
Set the secrets on the new project:
firebase functions:secrets:set MAILGUN_KEY
firebase functions:secrets:set STRIPE_APIKEY
firebase functions:secrets:set STRIPE_WEBHOOKSECRET
[ ] $ firebase deploy
to deploy:
Note: this will take a while. Also, it may fail the first couple times due to slow permission propagation, just rerun firebase deploy
[ ] Copy over the cloudRunId
into the new config file
https://resolvemarket-fm35sk365q-uc.a.run.app
fm35sk365q
package.json
$ firebase deploy --only firestore:rules
to redeploy security rulestheoremone.manifold.markets
:
[email protected]
theoremone
git branchNEXT_PUBLIC_FIREBASE_ENV
; VALUE: THEOREMONE
)Estimate: 30 minutes
Reality: 38 minutes
... + 13min to discover that we needed to set .env
for cloud functions
[J] Took me 90 minutes first time