Gave user Storage Admin role but still getting permission error - gserviceaccount.com does not have storage.objects.create access to bucket

2,426 views
Skip to first unread message

Scott

unread,
May 18, 2021, 11:10:56 AM5/18/21
to Google Cloud Developers
I'm trying to set up a Google Cloud bucket to upload objects from my Rails application (using the downloaded JSON key file for my user) and get the following error:-

Google::Cloud::PermissionDeniedError in OrganisationsController#update forbidden:

mypr...@my-project-83899-halo-leaf.iam.gserviceaccount.com does not have storage.objects.create access to halo-leaf-local/hu8oi0cmnFajlnojf32mlzfrrlth.

I only have one User in Google Cloud - myself. That account is the project Owner, and I've also given it Storage Admin permissions for my bucket, as shown below:-

Screenshot 2021-05-18 at 09.57.50.png

As far as I can see, Storage Admin should have all the permissions required to upload images. Does anyone know the issue here? I've also waited 12 hours for any changes to take place.


babdelrahman

unread,
May 19, 2021, 8:13:17 PM5/19/21
to Google Cloud Developers
Hello,
As the error message says :

mypr...@ XXXXXXXXXXX.gserviceaccount.com does not have storage.objects.create access to halo-leaf-local/hu8oi0cmnFajlnojf32mlzfrrlth.

You should edit the permissions of the service account and add the "storage.objects.create" access to it.
Reply all
Reply to author
Forward
0 new messages