ERROR: (gcloud.beta.functions.deploy) … message=[The caller does not have permission]

前端 未结 5 1204
情歌与酒
情歌与酒 2020-12-14 20:45

I am trying to deploy code from this repo:

https://github.com/anishkny/puppeteer-on-cloud-functions

in Google Cloud Build. My cloudbuild.yaml file contents a

5条回答
  •  隐瞒了意图╮
    2020-12-14 21:04

    According to Cloud Build documentation, for Cloud Functions you have to grant the "Project Editor" role to your service account.

    But, Cloud Functions documentation states that alternatively to using the Project Editor role, you can use "the Cloud Functions Developer role [but you have to] ensure that you have granted the Service Account User role". Regarding Service Accounts, it indicates to have "the CloudFunctions.ServiceAgent role on your project" and to "have permissions for trigger sources, such as Pub/Sub or the Cloud Storage bucket triggering your function".

    Due to those considerations, my understanding is that the documentation omitted to specify all the roles your service account would need and went directly to indicate to grant the Project Editor role.

提交回复
热议问题