【问题标题】:How to use the target command with IBM Cloud CLI如何将 target 命令与 IBM Cloud CLI 一起使用
【发布时间】:2018-11-21 11:17:04
【问题描述】:

使用 CLI 命令ibmcloud login 登录 IBM Cloud 后,我收到以下消息:

使用“ibmcloud target --cf”来定位 Cloud Foundry org/space 以交互方式,或使用 'ibmcloud target --cf-api ENDPOINT -o ORG -s SPACE' 来定位组织/空间。

于是我搜索了一下,找到了格式:

ibmcloud target [-r REGION_NAME] [-c ACCOUNT_ID] [-g RESOURCE_GROUP]
 [--cf] [-o ORG] [-s SPACE]

所以我输入ibmcloud target - Dallas-c 1770253-g Default--cf-o lior2-s lior2。 我的格式有问题吗?

【问题讨论】:

  • 在您发布的命令中,几乎所有内容都是错误的。在“达拉斯”之前有一个-,在-g--cf-o-s 之前没有空格。我无法确定这些问题是在您编写问题时引入的,还是您实际上尝试执行的命令。

标签: command-line-interface ibm-cloud


【解决方案1】:

我建议使用交互式格式ibmcloud target --cf。然后系统会提示您从有效值中进行选择。记住它们,下次使用它们作为参数。一个例子可能是:

ibmcloud target -r us-south -g default -s lior2

The IBM Cloud docs for the CLI has examples for the target command.

【讨论】:

  • HI #data_henrik 可以聘请你参加私人课程吗?
猜你喜欢
  • 1970-01-01
  • 2019-02-18
  • 1970-01-01
  • 2013-10-17
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2021-04-28
  • 1970-01-01
相关资源
最近更新 更多