【发布时间】:2022-01-08 15:07:36
【问题描述】:
我在 package.json 中将 Node Engine 14 升级到 16。现在我无法一次部署所有云功能。
我运行此命令一次部署所有功能。
"deploy-dev": "firebase use dev && firebase deploy --only functions"
终端上的错误消息
Functions deploy had errors with the following functions:
chatFieldDisableOnce(us-central1)
chatFieldReqUpdateOnce(us-central1)
contactYello(us-central1)
createPayment(us-central1)
makePayment(us-central1)
paymentCapture(us-central1)
reviewUpdateOnce(us-central1)
sendPostPromotion(us-central1)
vendorCountToSub(us-central1)
我查看日志。我发现了这个错误
{
"@type":"type.googleapis.com/google.cloud.audit.AuditLog",
"status": {
"code":8,
"message":"Build failed: Quota exceeded for quota metric 'Build Create requests' and limit 'Build Create requests per minute' of service 'cloudbuild.googleapis.com' for consumer 'project_number:number is here'."
},
"authenticationInfo":{"principalEmail":"xxx@gmail.com"},
"serviceName":"cloudfunctions.googleapis.com",
"methodName":"google.cloud.functions.v1.CloudFunctionsService.UpdateFunction",
"resourceName":"projects/yellochat-12b69/locations/us-central1/functions/sendPostPromotion"
}
我目前使用这个命令一一部署所有故障功能。这个工作正常。
firebase use dev && firebase deploy --only functions:function_name
【问题讨论】:
-
你同时部署多少个函数?
-
25 个函数。在 nodeJS 14 上运行时它运行没有任何问题。
-
当您在 nodejs 14 中部署所有 25 个函数时,它可以工作,对吧?不在nodejs16中?奇怪....因为你有 Cloud Build 配额,限制了同时 Cloud Build 的数量,所以节点 14 或 16 的部署模式相同,并以类似的方式使用 Cloud Build。
-
@guillaumeblaquiere 现在我在使用节点 16 重新启动 lap 相同命令后再次尝试。现在它工作正常,没有任何问题。
npm run deploy-dev
标签: typescript firebase google-cloud-functions