Skip to content
This repository has been archived by the owner on May 15, 2019. It is now read-only.

Permissions Issue with DataStore in the Functions Emulator #270

Open
ethan-seer opened this issue Aug 22, 2018 · 3 comments
Open

Permissions Issue with DataStore in the Functions Emulator #270

ethan-seer opened this issue Aug 22, 2018 · 3 comments

Comments

@ethan-seer
Copy link

ethan-seer commented Aug 22, 2018

Error

Error: 7 PERMISSION_DENIED: Missing or insufficient permissions.

Environment details

  • OS: High Sierra version 10.13.6
  • Node.js version: v6.14.4
  • npm version: 3.10.10
  • @google-cloud/functions-emulator version: 1.0.0-beta.5

Steps to reproduce

  1. Run: functions config set projectId my-project (with datastore enabled on the project level)
  2. Download the following repo: https://github.com/GoogleCloudPlatform/nodejs-docs-samples/tree/master/functions/datastore
  3. Deploy each trigger
functions deploy get --trigger-http
functions deploy set --trigger-http
functions deploy del --trigger-http
  1. Run the example: functions call set --data '{"kind":"Task","key":"sampletask1","value":{"description":"Buy milk"}}'
@briantq
Copy link

briantq commented Oct 2, 2018

I have encountered the same problem. It sounds like a IAM permission issue, but I can't figure it out as I am using the owner account for testing and can't get it to work.

@briantq
Copy link

briantq commented Oct 2, 2018

@ethan-seer I am not sure if you are still having this issue, but found this post that solved my problem https://stackoverflow.com/questions/39978077/gcloud-exceptions-forbidden-403-missing-or-insufficient-permissions I had used gcloud auth login and evidently I needed to use gcloud auth application-default login

@ethan-seer
Copy link
Author

Thanks @briantq . I figured out it was because I am in a beta that blocked my access. Thanks for f/u.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants