firebase / firebase-tools-ui

A local-first UI for Firebase Emulator Suite.
https://firebase.googleblog.com/2020/05/local-firebase-emulator-ui.html
Apache License 2.0
261 stars 60 forks source link

Gen2 functions should fail in the suite when using secret keys in functions.config() instead of Secret Manager #995

Open 70m3n opened 9 months ago

70m3n commented 9 months ago

The Firebase Emulator Suite is very handy when developing apps using Firebase. So thanks for making it!

I recently updated a Firebase function to gen2. When deploying the function to production it failed because gen2 doesn't support storing secret keys in the functions.config(), part of the firebase-functions package. Instead one has to use Secret Manager in GC and read the values via process.env.

The Firebase Emulator Suite doesn't have the same requirement. It still supports "the old way". Thus, I was unable to detect this error in my code before updating my function in production.