尝试部署Firebase功能,未找到默认服务帐户 [英] Trying to deploy firebase functions, Default service account not found

查看:99
本文介绍了尝试部署Firebase功能,未找到默认服务帐户的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将以下简单功能上传到我的Firebase控制台

I am trying to upload the following simple function to my firebase console

const functions = require('firebase-functions');

exports.helloWorld = functions.https.onRequest((request, response) => {
 response.send("Hello from Firebase!");
});

但是,它失败并显示以下错误:

However, it fails with the following error:

HTTP Error: 400, Default service account 'myfirebase-projecte@appspot.gserviceaccount.com' doesn't exist. Please recreate this account (for example by disabling and enabling the Cloud Functions API), or specify a different account.

目前,我在Firebase和Google Cloud Platforms之间无法解决此错误,对此感到困惑.

At this point I am confused between Firebase and Google Cloud Platforms and where this error can be fixed.

推荐答案

您好!兔子洞!我想到了.似乎我不小心删除了我的默认服务帐户(非常感谢30天之内),并且能够按照以下非常具体且非常有用的说明进行恢复,

Hello from the rabbit hole! I figured it out. Seems like I accidentally deleted my Default Service Account (thankfully within 30 days) and I was able to recover it by following these very specific and very useful instructions https://cloud.google.com/iam/docs/creating-managing-service-accounts#undeleting since it's not possible to re-activate using the console's interface.

基本上,您必须查找删除发生的时间,从此事件中获取帐户的ID,然后使用Google Cloud终端和gcloud beta iam service-accounts undelete [ACCOUNT_ID]命令将其还原. !

Basically, you have to find when the deletion occured, get the account's ID from this event and then restore it using the Google Cloud terminal with the gcloud beta iam service-accounts undelete [ACCOUNT_ID] command. Phew!

这篇关于尝试部署Firebase功能,未找到默认服务帐户的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆