Deploying Firebase Functions hit build quota (Build Create requests per minute)

489 views Asked by At

I have a Firebase project with 55 Functions. I sometimes got a deployment error saying that I hit the quota limit for Build Create requests per minute (the quota right now is 60) with the simplest deployment command,

firebase deploy --only functions

And the CLI suggested me to deploy the remaining again using a command like this,

firebase deploy --only functions:functionA,functions:functionB

As it is a per minute quota, I was expecting the CLI to workaround the quota seamlessly. But it's not.

I sent an email to Firebase Support and they advised me to always use only 75% of the quota at one time when trying to deploy functions, but I wonder how everyone workarounds this quota issue ?

I read about organizing functions in groups in the documentation and deploy group-by-group, but I wonder if there is other solutions ?

1

There are 1 answers

0
vitooh On

Well I think that you can use Cloud Build. BTW not sure if you know, that all your Firebase projects and functions are available in GCP as well. You can change and deploy them directly in GCP Console (direct link).

In Cloud Build there is functionality that lets you to deploy to Firebase with convenient configuration file in yaml or json.

The configuration file contain steps of your deploy and you can setup a timeout between them (reference). So, you can create those steps with --only flag with control of time and you can use it created file many times and just adjust it when you add new function.

I think this will help you to avoid hitting quota limits, and I suppose you can use other features of Cloud Build as well.