【问题标题】:Google cloud iam unrecognized arguments when trying to create a key谷歌云在尝试创建密钥时出现无法识别的参数
【发布时间】:2018-02-06 21:06:03
【问题描述】:

我正在尝试为学校作业配置谷歌云服务,但是当我尝试运行命令时:

gcloud iam service-accounts keys create key.json -iam-account quickstart@ivannearshorepractice194420.iam.gserviceaccount.com

ivannearshorepractice 是我的项目的名称,我收到以下错误:

ERROR: (gcloud.iam.service-accounts.keys.create) unrecognized arguments:
  -iam-account
  quickstart@ivannearshorepractice194420.iam.gserviceaccount.com

这是什么原因,我该如何解决?

【问题讨论】:

    标签: google-cloud-platform gcloud service-accounts


    【解决方案1】:

    对不起!事实证明,我的作业说明有错字,并且该命令在 -iam-account 之前缺少一个额外的破折号:P 正确的命令:

    gcloud iam service-accounts keys create key.json --iam-account quickstart@ivannearshorepractice194420.iam.gserviceaccount.com
    

    如果有人遇到类似问题,请参考: https://cloud.google.com/iam/docs/creating-managing-service-account-keys

    【讨论】:

    • 确保您始终阅读错误 ;) - ERROR: (gcloud.iam.service-accounts.keys.create) unrecognized arguments: -iam-account
    猜你喜欢
    • 2016-10-28
    • 2021-03-27
    • 2023-03-15
    • 1970-01-01
    • 2014-07-11
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-03-18
    相关资源
    最近更新 更多