google-cloud-powershell icon indicating copy to clipboard operation
google-cloud-powershell copied to clipboard

Can't specify the scopes for new GCE instances.

Open ivannaranjo opened this issue 8 years ago • 3 comments

Neither the New-GceInstanceConfig or Add-GceInstance have a -Scope parameter to specify the list of scopes to use for that instance.

There should be a param to specify what OAUTH scopes to authorize the instance for.

ivannaranjo avatar Mar 06 '17 14:03 ivannaranjo

@ivannaranjo, you can supply a service account when creating instances. Service account can be built with New-GceServiceAccountConfig and given the appropriate scopes. Is this what you are looking for?

quoctruong avatar Mar 06 '17 18:03 quoctruong

No, that is not what I am looking for, as creating a service account just to specify the list of scopes is too much overhead. This will also require creating service accounts for every combination of scopes required.

Most of the time I just want to specify the scopes that I need, and let the tool use the default service account for me.

ivannaranjo avatar Apr 06 '17 12:04 ivannaranjo

@ivannaranjo, I see. I can add a -Scope parameter to the cmdlets as another alternative for -ServiceAccount parameter.

quoctruong avatar Apr 26 '17 20:04 quoctruong