I was trying to deploy my first firebase cloud function using firebase cli but I encountered an error instead :
C:\Users\Anurag Tripathi\Desktop\firebasecloudfunction> firebase deploy --only functions
Error: Missing permissions required for functions deploy. You must have permission iam.serviceAccounts.ActAs on service account [email protected].
To address this error, ask a project Owner to assign your account the "Service Account User" role from this URL:
https://console.cloud.google.com/iam-admin/iam?project=project_number
I tried to solve the problem by following the instruction but didn't get any success . Please help.
Edit : I have abandoned the project :( , so I really can't test the answers. Thanks all for the answers and comments. I will accept the most upvoted answer.
It turned out I had the wrong project name in the .firebaserc file. After changing the name to the correct google cloud project name it worked.
As specified in the docs, apart from the Service Account User role, you should assign the Cloud Functions Admin role to the Service Account that you are using to deploy the functions
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With