-
Notifications
You must be signed in to change notification settings - Fork 205
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
allUsers > Cloud Functions Invoker not added to HTTP functions in Node 10 runtime #646
Comments
I found a few problems with this issue:
|
Hello, I've had the same problem today, and thought I'd chime in with my temp fix (Including issues template for clarification). Related issuesNone. [REQUIRED] Version infonode: 10.13.0 firebase-functions: 3.0.2 firebase-tools: 7.6.1 firebase-admin: 8.8.0 [REQUIRED] Steps to reproduce
[REQUIRED] Expected behaviorFor a newly deployed cloud function to have allUsers in the permissions by default. [REQUIRED] Actual behaviorCloud function has no Cloud Functions Invoker, meaning all access is denied. Were you able to successfully deploy your functions?Yes. Temp fix:In the cloud console functions page, select a function to show the info panel. In the permissions tab, select ADD MEMBER. In the new members field, type allUsers. In the roles drop down, select cloud functions, then cloud functions invoker, and save. It actually sort of makes sense for a function to have restricted permissions when it's first created, however I'm used to the default permissions being present, so it's a bug (or new feature) that definitely threw me off. Of course this doesn't fix the underlying problem, but hope it helps. |
You need to upgrade the CLI to
|
@mbleigh Thanks for the info! |
Hello! |
@pedrocarloto The screenshot is probably taken from https://console.cloud.google.com/functions - click on the function you are having issues with and look in the "Permissions" tab. Firebase CLI tool makes a request to the Google Cloud Functions API to update the permissions post-deploy. Sometimes, this request may fail for various reasons (bad connection, not sufficient permission, etc). There should be a log entry when the request fails - can you share what you find there? |
Hei @taeold! since I have about 80 functions I would like to know how many don't have the role. I have tried the IAM interface, but it does not include the "Cloud Functions Invoker": Regarding the logs, the deployment was done through GitHub Actions and I have looked there, but didn't find that request. I also searched on the function log itself on Google Cloud Log Explorer but also did not find that request. Where should I be looking? Thank you! |
For anyone running into this recently, I resolved it by:
|
[REQUIRED] Version info
^3.0.2
node:
10
firebase-functions:
HTTP
firebase-tools:
7.4.0
[REQUIRED] Test case
Creating a new HTTP function from the cli by deploying code with
firebase deploy --only functions
creates a function which throws a 403 when called directly or CORS error when using firebase.functions().httpsCallable from the client[REQUIRED] Steps to reproduce
As above
[REQUIRED] Expected behavior
The function should have 'allUsers > Cloud Functions Invoker' so it can be called from the client
[REQUIRED] Actual behavior
It doesn't have 'allUsers > Cloud Functions Invoker' and so throws a 403
Were you able to successfully deploy your functions?
Yes
The text was updated successfully, but these errors were encountered: