Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Firebase CLI deploy error: "Deploys to runtimes below Node.js 10 are now disabled in the Firebase CLI."

I have a project using Cloud Functions for Firebase, and after updating the Firebase CLI to version 9.0.0, I am getting an error message:

Error: package.json in functions directory has an engines field which is unsupported. Valid choices are: {"node": "10"}, {"node":"12"}, and {"node":"14"}.

Deploys to runtimes below Node.js 10 are now disabled in the Firebase CLI. Existing Node.js 8 functions will stop executing on 2021-03-15. Update existing functions to Node.js 10 or greater as soon as possible.

I understand that node 8 is now unsupported, but I want to keep deploying and running my functions on the Spark payment plan which doesn't require billing until things are shut off on March 15, 2021. How can I do this?

like image 880
Doug Stevenson Avatar asked Dec 16 '20 03:12

Doug Stevenson


1 Answers

Since version 9.0.0, the Firebase CLI has fully removed node 8 as an option. If you can't take the recommended advice of upgrading to node 10 (which requires also upgrading to a payment plan), then you will have to downgrade your CLI, which you can use until node 8 is shut off completely on March 15.

Run this to downgrade to the latest version of the CLI before version 9:

npm install -g firebase-tools@8

This should get you version 8.20.0 of the CLI until you choose to upgrade again.

like image 67
Doug Stevenson Avatar answered Oct 13 '22 00:10

Doug Stevenson