Merge pull request #101170 from jeremyje/fixscopes

GCE Windows: Use authenticated HTTP GET against GCS if VM has cloud-p…
This commit is contained in:
Kubernetes Prow Robot 2021-04-15 17:44:21 -07:00 committed by GitHub
commit 2342ac3cfa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -295,7 +295,7 @@ function Check-StorageScope {
While($true) { While($true) {
$data = Get-InstanceMetadata -Key "service-accounts/default/scopes" $data = Get-InstanceMetadata -Key "service-accounts/default/scopes"
if ($data) { if ($data) {
return ($data -match "auth/devstorage") return ($data -match "auth/devstorage") -or ($data -match "auth/cloud-platform")
} }
Start-Sleep -Seconds 1 Start-Sleep -Seconds 1
} }