Skip to main content

clusters

Overview

Nameclusters
TypeResource
Idgoogle.container.clusters

Fields

NameDatatypeDescription
idstringOutput only. Unique id for the cluster.
namestringThe name of this cluster. The name must be unique within this project and location (e.g. zone or region), and can be up to 40 characters with the following restrictions: Lowercase letters, numbers, and hyphens only. Must start with a letter. * Must end with a number or a letter.
descriptionstringAn optional description of this cluster.
databaseEncryptionobjectConfiguration of etcd encryption.
initialNodeCountintegerThe number of nodes to create in this cluster. You must ensure that your Compute Engine resource quota is sufficient for this number of instances. You must also have available firewall and routes quota. For requests, this field should only be used in lieu of a "node_pool" object, since this configuration (along with the "node_config") will be used to create a "NodePool" object with an auto-generated name. Do not use this and a node_pool at the same time. This field is deprecated, use node_pool.initial_node_count instead.
initialClusterVersionstringThe initial Kubernetes version for this cluster. Valid versions are those found in validMasterVersions returned by getServerConfig. The version can be upgraded over time; such upgrades are reflected in currentMasterVersion and currentNodeVersion. Users may specify either explicit versions offered by Kubernetes Engine or version aliases, which have the following behavior: - "latest": picks the highest valid Kubernetes version - "1.X": picks the highest valid patch+gke.N patch in the 1.X version - "1.X.Y": picks the highest valid gke.N patch in the 1.X.Y version - "1.X.Y-gke.N": picks an explicit Kubernetes version - "","-": picks the default Kubernetes version
tpuIpv4CidrBlockstring[Output only] The IP address range of the Cloud TPUs in this cluster, in CIDR notation (e.g. 1.2.3.4/29).
labelFingerprintstringThe fingerprint of the set of labels for this cluster.
monitoringConfigobjectMonitoringConfig is cluster monitoring configuration.
defaultMaxPodsConstraintobjectConstraints applied to pods.
currentNodeVersionstring[Output only] Deprecated, use NodePools.version instead. The current version of the node software components. If they are currently at multiple versions because they're in the process of being upgraded, this reflects the minimum version of all nodes.
ipAllocationPolicyobjectConfiguration for controlling how IPs are allocated in the cluster.
legacyAbacobjectConfiguration for the legacy Attribute Based Access Control authorization mode.
resourceLabelsobjectThe resource labels for the cluster to use to annotate any related Google Compute Engine resources.
instanceGroupUrlsarrayDeprecated. Use node_pools.instance_group_urls.
costManagementConfigobjectConfiguration for fine-grained cost management feature.
masterAuthobjectThe authentication information for accessing the master endpoint. Authentication can be done using HTTP basic auth or using client certificates.
loggingServicestringThe logging service the cluster should use to write logs. Currently available options: logging.googleapis.com/kubernetes - The Cloud Logging service with a Kubernetes-native resource model logging.googleapis.com - The legacy Cloud Logging service (no longer available as of GKE 1.15). * none - no logs will be exported from the cluster. If left as an empty string,logging.googleapis.com/kubernetes will be used for GKE 1.14+ or logging.googleapis.com for earlier versions.
meshCertificatesobjectConfiguration for issuance of mTLS keys and certificates to Kubernetes pods.
shieldedNodesobjectConfiguration of Shielded Nodes feature.
confidentialNodesobjectConfidentialNodes is configuration for the confidential nodes feature, which makes nodes run on confidential VMs.
enableTpubooleanEnable the ability to use Cloud TPUs in this cluster.
selfLinkstring[Output only] Server-defined URL for the resource.
fleetobjectFleet is the fleet configuration for the cluster.
verticalPodAutoscalingobjectVerticalPodAutoscaling contains global, per-cluster information required by Vertical Pod Autoscaler to automatically adjust the resources of pods controlled by it.
conditionsarrayWhich conditions caused the current cluster state.
networkstringThe name of the Google Compute Engine network to which the cluster is connected. If left unspecified, the default network will be used.
loggingConfigobjectLoggingConfig is cluster logging configuration.
expireTimestring[Output only] The time the cluster will be automatically deleted in RFC3339 text format.
currentMasterVersionstring[Output only] The current software version of the master endpoint.
autopilotobjectAutopilot is the configuration for Autopilot settings on the cluster.
releaseChannelobjectReleaseChannel indicates which release channel a cluster is subscribed to. Release channels are arranged in order of risk. When a cluster is subscribed to a release channel, Google maintains both the master version and the node version. Node auto-upgrade defaults to true and cannot be disabled.
autoscalingobjectClusterAutoscaling contains global, per-cluster information required by Cluster Autoscaler to automatically adjust the size of the cluster and create/delete node pools based on the current needs.
nodeConfigobjectParameters that describe the nodes in a cluster. GKE Autopilot clusters do not recognize parameters in NodeConfig. Use AutoprovisioningNodePoolDefaults instead.
etagstringThis checksum is computed by the server based on the value of cluster fields, and may be sent on update requests to ensure the client has an up-to-date value before proceeding.
maintenancePolicyobjectMaintenancePolicy defines the maintenance policy to be used for the cluster.
statusMessagestring[Output only] Deprecated. Use conditions instead. Additional information about the current status of this cluster, if available.
clusterIpv4CidrstringThe IP address range of the container pods in this cluster, in CIDR notation (e.g. 10.96.0.0/14). Leave blank to have one automatically chosen or specify a /14 block in 10.0.0.0/8.
nodeIpv4CidrSizeinteger[Output only] The size of the address space on each node for hosting containers. This is provisioned from within the container_ipv4_cidr range. This field will only be set when cluster is in route-based network mode.
createTimestring[Output only] The time the cluster was created, in RFC3339 text format.
masterAuthorizedNetworksConfigobjectConfiguration options for the master authorized networks feature. Enabled master authorized networks will disallow all external traffic to access Kubernetes master through HTTPS except traffic from the given CIDR blocks, Google Compute Engine Public IPs and Google Prod IPs.
workloadIdentityConfigobjectConfiguration for the use of Kubernetes Service Accounts in GCP IAM policies.
privateClusterConfigobjectConfiguration options for private clusters.
notificationConfigobjectNotificationConfig is the configuration of notifications.
statusstring[Output only] The current status of this cluster.
endpointstring[Output only] The IP address of this cluster's master endpoint. The endpoint can be accessed from the internet at https://username:password@endpoint/. See the masterAuth property of this resource for username and password information.
securityPostureConfigobjectSecurityPostureConfig defines the flags needed to enable/disable features for the Security Posture API.
locationsarrayThe list of Google Compute Engine zones in which the cluster's nodes should be located. This field provides a default value if NodePool.Locations are not specified during node pool creation. Warning: changing cluster locations will update the NodePool.Locations of all node pools and will result in nodes being added and/or removed.
nodePoolAutoConfigobjectNode pool configs that apply to all auto-provisioned node pools in autopilot clusters and node auto-provisioning enabled clusters.
nodePoolDefaultsobjectSubset of Nodepool message that has defaults.
networkPolicyobjectConfiguration options for the NetworkPolicy feature. https://kubernetes.io/docs/concepts/services-networking/networkpolicies/
resourceUsageExportConfigobjectConfiguration for exporting cluster resource usages.
authenticatorGroupsConfigobjectConfiguration for returning group information from authenticators.
identityServiceConfigobjectIdentityServiceConfig is configuration for Identity Service which allows customers to use external identity providers with the K8S API
zonestring[Output only] The name of the Google Compute Engine zone in which the cluster resides. This field is deprecated, use location instead.
binaryAuthorizationobjectConfiguration for Binary Authorization.
locationstring[Output only] The name of the Google Compute Engine zone or region in which the cluster resides.
enableKubernetesAlphabooleanKubernetes alpha features are enabled on this cluster. This includes alpha API groups (e.g. v1alpha1) and features that may not be production ready in the kubernetes version of the master and nodes. The cluster has no SLA for uptime and master/node upgrades are disabled. Alpha enabled clusters are automatically deleted thirty days after creation.
enableK8sBetaApisobjectK8sBetaAPIConfig , configuration for beta APIs
networkConfigobjectNetworkConfig reports the relative names of network & subnetwork.
subnetworkstringThe name of the Google Compute Engine subnetwork to which the cluster is connected.
addonsConfigobjectConfiguration for the addons that can be automatically spun up in the cluster, enabling additional functionality.
monitoringServicestringThe monitoring service the cluster should use to write metrics. Currently available options: "monitoring.googleapis.com/kubernetes" - The Cloud Monitoring service with a Kubernetes-native resource model monitoring.googleapis.com - The legacy Cloud Monitoring service (no longer available as of GKE 1.15). * none - No metrics will be exported from the cluster. If left as an empty string,monitoring.googleapis.com/kubernetes will be used for GKE 1.14+ or monitoring.googleapis.com for earlier versions.
servicesIpv4Cidrstring[Output only] The IP address range of the Kubernetes services in this cluster, in CIDR notation (e.g. 1.2.3.4/29). Service addresses are typically put in the last /16 from the container CIDR.
nodePoolsarrayThe node pools associated with this cluster. This field should not be set if "node_config" or "initial_node_count" are specified.
currentNodeCountinteger[Output only] The number of nodes currently in the cluster. Deprecated. Call Kubernetes API directly to retrieve node information.

Methods

NameAccessible byRequired ParamsDescription
projects_locations_clusters_getSELECTclustersId, locationsId, projectsIdGets the details of a specific cluster.
projects_locations_clusters_listSELECTlocationsId, projectsIdLists all clusters owned by a project in either the specified zone or all zones.
projects_zones_clusters_getSELECTclusterId, projectId, zoneGets the details of a specific cluster.
projects_zones_clusters_listSELECTprojectId, zoneLists all clusters owned by a project in either the specified zone or all zones.
projects_locations_clusters_createINSERTlocationsId, projectsIdCreates a cluster, consisting of the specified number and type of Google Compute Engine instances. By default, the cluster is created in the project's default network. One firewall is added for the cluster. After cluster creation, the Kubelet creates routes for each node to allow the containers on that node to communicate with all other instances in the cluster. Finally, an entry is added to the project's global metadata indicating which CIDR range the cluster is using.
projects_zones_clusters_createINSERTprojectId, zoneCreates a cluster, consisting of the specified number and type of Google Compute Engine instances. By default, the cluster is created in the project's default network. One firewall is added for the cluster. After cluster creation, the Kubelet creates routes for each node to allow the containers on that node to communicate with all other instances in the cluster. Finally, an entry is added to the project's global metadata indicating which CIDR range the cluster is using.
projects_locations_clusters_deleteDELETEclustersId, locationsId, projectsIdDeletes the cluster, including the Kubernetes endpoint and all worker nodes. Firewalls and routes that were configured during cluster creation are also deleted. Other Google Compute Engine resources that might be in use by the cluster, such as load balancer resources, are not deleted if they weren't present when the cluster was initially created.
projects_zones_clusters_deleteDELETEclusterId, projectId, zoneDeletes the cluster, including the Kubernetes endpoint and all worker nodes. Firewalls and routes that were configured during cluster creation are also deleted. Other Google Compute Engine resources that might be in use by the cluster, such as load balancer resources, are not deleted if they weren't present when the cluster was initially created.
_projects_locations_clusters_listEXEClocationsId, projectsIdLists all clusters owned by a project in either the specified zone or all zones.
projects_locations_clusters_check_autopilot_compatibilityEXECclustersId, locationsId, projectsIdChecks the cluster compatibility with Autopilot mode, and returns a list of compatibility issues.
projects_locations_clusters_complete_ip_rotationEXECclustersId, locationsId, projectsIdCompletes master IP rotation.
projects_locations_clusters_set_addonsEXECclustersId, locationsId, projectsIdSets the addons for a specific cluster.
projects_locations_clusters_set_legacy_abacEXECclustersId, locationsId, projectsIdEnables or disables the ABAC authorization mechanism on a cluster.
projects_locations_clusters_set_locationsEXECclustersId, locationsId, projectsIdSets the locations for a specific cluster. Deprecated. Use projects.locations.clusters.update instead.
projects_locations_clusters_set_loggingEXECclustersId, locationsId, projectsIdSets the logging service for a specific cluster.
projects_locations_clusters_set_maintenance_policyEXECclustersId, locationsId, projectsIdSets the maintenance policy for a cluster.
projects_locations_clusters_set_master_authEXECclustersId, locationsId, projectsIdSets master auth materials. Currently supports changing the admin password or a specific cluster, either via password generation or explicitly setting the password.
projects_locations_clusters_set_monitoringEXECclustersId, locationsId, projectsIdSets the monitoring service for a specific cluster.
projects_locations_clusters_set_network_policyEXECclustersId, locationsId, projectsIdEnables or disables Network Policy for a cluster.
projects_locations_clusters_set_resource_labelsEXECclustersId, locationsId, projectsIdSets labels on a cluster.
projects_locations_clusters_start_ip_rotationEXECclustersId, locationsId, projectsIdStarts master IP rotation.
projects_locations_clusters_updateEXECclustersId, locationsId, projectsIdUpdates the settings of a specific cluster.
projects_zones_clusters_complete_ip_rotationEXECclusterId, projectId, zoneCompletes master IP rotation.
projects_zones_clusters_legacy_abacEXECclusterId, projectId, zoneEnables or disables the ABAC authorization mechanism on a cluster.
projects_zones_clusters_locationsEXECclusterId, projectId, zoneSets the locations for a specific cluster. Deprecated. Use projects.locations.clusters.update instead.
projects_zones_clusters_loggingEXECclusterId, projectId, zoneSets the logging service for a specific cluster.
projects_zones_clusters_masterEXECclusterId, projectId, zoneUpdates the master for a specific cluster.
projects_zones_clusters_monitoringEXECclusterId, projectId, zoneSets the monitoring service for a specific cluster.
projects_zones_clusters_resource_labelsEXECclusterId, projectId, zoneSets labels on a cluster.
projects_zones_clusters_set_maintenance_policyEXECclusterId, projectId, zoneSets the maintenance policy for a cluster.
projects_zones_clusters_set_master_authEXECclusterId, projectId, zoneSets master auth materials. Currently supports changing the admin password or a specific cluster, either via password generation or explicitly setting the password.
projects_zones_clusters_set_network_policyEXECclusterId, projectId, zoneEnables or disables Network Policy for a cluster.
projects_zones_clusters_start_ip_rotationEXECclusterId, projectId, zoneStarts master IP rotation.
projects_zones_clusters_updateEXECclusterId, projectId, zoneUpdates the settings of a specific cluster.