我们直接运行就可以创建了: $ gcloud compute instances create pkslow-vm\--project=pkslow\--zone=us-west1-a\--machine-type=e2-micro\--network-interface=network-tier=PREMIUM,subnet=default\--maintenance-policy=MIGRATE\--service-account=admin-for-all@pkslow.iam.gserviceaccount.com\--scopes=https...
根据gCloud SDK documentions ofgcloud iam,有特定的命令来设置roles和service-accounts。
+ + *Option 3:* Leave +accessKey and secretKey blank, and set the irsaRole field (IAM roles for +service accounts). + +|machine_provisioner.providers.ec2.enabled |bool |`+false+` |Set to +enable EC2 as a virtual machine provider + +|machine_provisioner.providers.gcp.enabled |bool |...
* admin-for-all@pkslow.iam.gserviceaccount.com Tosetthe active account, run: $ gcloud configsetaccount`ACCOUNT`$ gcloud config list[core]account=admin-for-all@pkslow.iam.gserviceaccount.com disable_usage_reporting=True project=pkslow Your active configuration is:[default] Bash Copy Use the gc...