I have an instance running with access scope 'Set Access for each API', and explicitly allowing Compute Engine API with Read-Write access as showing in this below image.
So I logged inside the instance via SSH, and I tried to run this command:-
gcloud compute instances list
and I got an error:
- Required 'compute.zones.list' permission for 'projects/dotted-hxxl-xxx'
My user is having explicitly allowing access to compute Engine API but still I am getting the error. I shouldn't get this error right? What am I missing here?
when you are logged into an instance, the permissions that you get aren't these of your users but these of the compute engine provided by the metadata server.