Google Cloud 控制台、Google Cloud CLI 或 Terraform,您可以从与 GKE On-Prem API 建立网络连接的任何计算机运行。这些标准工具使用在 Google Cloud 基础设施上运行的 GKE On-Prem API,它们统称为 GKE On-Prem API 客户端。如需管理集群的生命周期,GKE On-Prem API 必须使用创建集群时指定的 Google Cloud 区域,将有关集群状态的元数据存储在 Google Cloud中。此元数据可让 API 管理集群生命周期,并且不包含特定于工作负载的数据。
无论您使用哪个工具创建集群,您收集并提供给该工具的信息都是相同的,例如集群节点机器的 IP 地址和负载均衡器 VIP。
您可以选择最适合您的应用场景和环境的工具。例如:
在开发环境中首次安装时,建议您使用 Google Cloud 控制台,因为界面提供了额外的指导和帮助。
如果您的组织已在使用 gcloud CLI 或 Terraform 管理其他 Google Cloud 资源,则您可能也需要将这些工具用于 Google Distributed Cloud。
如果您的组织有监管要求或限制,建议您限制对 Google Cloud 的依赖,并在管理员工作站上使用 gkectl 来创建集群和管理集群生命周期。
如果您使用 gkectl 创建集群,默认情况下,它会注册到 GKE On-Prem API。您也可以在创建集群后注册集群,这可让您使用 GKE On-Prem API 客户端。
GKE On-Prem API 客户端的限制
gkectl 工具最成熟的方面就是它支持的功能。我们建议您在进行选择时查看 GKE On-Prem API 客户端的功能。以下列表显示了 GKE On-Prem API 客户端不支持的功能。
[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["很难理解","hardToUnderstand","thumb-down"],["信息或示例代码不正确","incorrectInformationOrSampleCode","thumb-down"],["没有我需要的信息/示例","missingTheInformationSamplesINeed","thumb-down"],["翻译问题","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-09-03。"],[],[],null,["Google Distributed Cloud provides you a choice of tools to create clusters and\nmanage the cluster lifecycle operations (update, upgrade, and delete):\n\n- The command-line tool `gkectl`, which you run on your admin workstation in your on-premises data center. You create a [configuration file](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/user-cluster-configuration-file-latest) that describes the cluster network, load balancing, and other cluster features. You specify this file on the command line to `gkectl`.\n- The Google Cloud console, Google Cloud CLI, or [Terraform](https://www.terraform.io), which you can run from any computer that has network connectivity to the GKE On-Prem API. These standard tools use the [GKE On-Prem API](/kubernetes-engine/distributed-cloud/reference/on-prem-api-overview), which runs on Google Cloud infrastructure. Collectively, the standard tools are referred to as the *GKE On-Prem API clients*. To manage the lifecycle of your clusters, the GKE On-Prem API must store metadata about your cluster's state in Google Cloud, in the Google Cloud region that you specify when creating the cluster. This metadata lets the API manage the cluster lifecycle and doesn't include workload-specific data.\n\nNo matter which tool you use to create clusters, the information that\nyou gather and provide to the tool, such as the IP addresses\nof cluster node machines and load balancer VIPs, is the same.\n\nThis selection lets you choose the best tool for your use case and\nenvironment. For example:\n\n- For your first installations in a development environment, you might want to use the Google Cloud console because the user interface provides additional guidance and help.\n- If your organization already uses the gcloud CLI or Terraform to manage other Google Cloud resources, you will probably want to use these tools for Google Distributed Cloud as well.\n- If your organization has regulatory requirements or restrictions, you might need to limit your reliance on Google Cloud and use `gkectl` on your admin workstation to create clusters and manage cluster lifecycle.\n\nIf you create a cluster with `gkectl`, it will be enrolled with the\nGKE On-Prem API by default. You can also\n[enroll the cluster](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/enroll-cluster) after it is created,\nwhich lets you use the GKE On-Prem API clients.\n\nLimitations with the GKE On-Prem API clients\n\nThe `gkectl` tool is the most mature as far as features that it supports. We\nrecommend that you review the capabilities for the GKE On-Prem API clients when\nmaking a choice. The following list shows the features that are not supported by\nthe GKE On-Prem API clients.\n\n- [Advanced clusters](/kubernetes-engine/distributed-cloud/vmware/docs/concepts/advanced-clusters)\n- Secret management and rotation\n- Certificate rotation\n- Authentication\n- Usage metering\n- Application level logging and monitoring\n- Advanced networking\n- Windows node pools\n\nThe following list describes additional limitations with the GKE On-Prem API\nclients:\n\n- The gcloud CLI isn't supported for any admin cluster lifecycle\n operation. You can use `gkectl`, the console, the\n gcloud CLI, or Terraform to create admin clusters.\n\n- The `gkectl` command-line tool is the only tool available for upgrading,\n updating, and deleting admin clusters.\n\n- Only `gkectl` and Terraform support using a\n [private registry](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/private-registry).\n\n- The kind of load balancer for an admin cluster and its user clusters must be\n the same. The only exception is if the admin cluster uses Seesaw, then the\n user clusters can use MetalLB. If you want your admin and user clusters to use\n different kinds of load balancers, you must create the clusters using\n `gkectl`.\n\n- When you create a user cluster using the Google Cloud console, all the\n [`vCenter` settings](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/user-cluster-configuration-file-latest#vcenter-section)\n are inherited from the admin cluster. If you need a user cluster to have\n different `vCenter` settings from its admin cluster, use the\n gcloud CLI, Terraform, or `gkectl` to create the user cluster.\n\nCheck on these limitations from time to time as the GKE On-Prem API clients\nevolve."]]