Access denied for service account (permission issue?) when importing a csv from cloud storage to cloud sql

放肆的年华 提交于 2019-12-06 11:34:28

You are trying to do an import from your bucket to your Cloud SQL instance, but, said import is going to be made by a service account, one in particular, which can be seen in the “Service account” section while seeing the details of your Cloud SQL instance.

It might be that the CloudSQL service account does not have appropriate permissions to access the Cloud Storage bucket with the data to import.

In order to create a successful import between SQL instance and Storage buckets, proper permissions should be set first. You should give to the service account "oosyrcl32gnzypxg4uhqw54uab@speckle-umbrella-27.iam.gserviceaccount.com" the Storage Object Viewer role.

  1. Go to: https://console.cloud.google.com/iam-admin/iam
  2. Click Add, to add a new member.
  3. Paste the gserviceaccount.com email address that was presented in the error message into the New Members field.
  4. Add 2 roles:
    1. Cloud SQL Viewer
    2. Storage Object Admin
  5. Click Save.
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!