我已经使用 GCE 和 gcloud 几个星期了。去年 12 月 3 日 ( https://cloud.google.com/compute/docs/vpn ) 发布了一组新的 VPN 工具,我需要开始使用它们进行测试。
问题是 gcloud 似乎无法识别这套新工具,并且出现以下错误:
$ gcloud compute target-vpn-gateways create --region us-central1 --network default vpn1
ERROR: (gcloud.compute) Invalid choice: 'target-vpn-gateways'.
$ gcloud compute vpn-tunnels describe
ERROR: (gcloud.compute) Invalid choice: 'vpn-tunnels'
target-vpn-gateways和vpn-tunnels不属于命令组。
所以,我虽然更新了核心和计算组件,但它们都是最新的。这似乎太新了,因此 Google Cloud 文档中目前没有关于更新 SDK 以使用这些 VPN 工具的信息。
有任何想法吗?我正在使用 OSX 以防万一。
提前非常感谢!
编辑:
截至 2015 年 3 月,文档已更新,现在处于测试阶段:
https://cloud.google.com/compute/docs/vpn
因此,根据此更新回答我自己的问题,可以通过以下方式更新组件来访问 beta VPN 功能:
$ gcloud components update beta