-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
[REQUIRED] Environment info
firebase-tools: 12.4.4 (should be the same on latest version)
Platform: Docker on Ubuntu on Github Action Runner
[REQUIRED] Test case
Any normal firebase project with some functions. Optionally it is using a CI/CD (non-interactive) to deploy. Adjusting the minInstances to increase the minimum bill of the project, in our case 1 is enough.
.runWith({
minInstances:1
})
[REQUIRED] Steps to reproduce
Deploy the adjusted function optimally via a non interactive terminal, ie. github action.
[REQUIRED] Expected behavior
The function should be deployed with minInstance=1.
[REQUIRED] Actual behavior
Error message: Pass the --force option to deploy functions that increase the minimum bill
and deployment is canceled.
The problem is that we can't use the --force
flag as this would also auto delete functions. From the help section this behaviour is also not clear. There the force flag is only documented to delete functions:
-f, --force delete Cloud Functions missing from the current working directory without confirmation
Solution Idea
The --force
flag should not be reused as a helper for other stuff than the deletion. Probably a separate flag for that would suffice, eg. --allow-bill-increase
.
That flag would replace force in this file:
if (options.force) { |