Deploying Google Kubernetes Engine
Google ACE ACE · Planning and implementing a cloud solution
What GKE is
Google Kubernetes Engine (GKE) is Google's managed Kubernetes service. Kubernetes orchestrates containers: it decides which machines run them, restarts them when they fail, scales them up and down, and exposes them to the network. GKE manages the Kubernetes control plane — the API server, scheduler, and controllers — while the nodes (the Compute Engine VMs that actually run the containers) are managed either by you (Standard mode) or by Google (Autopilot mode). The exam guide lists GKE deployment as a core skill: creating clusters with different configurations, installing the kubectl command-line tool, and deploying a containerized application.
Autopilot vs Standard
GKE has two modes of operation, and choosing between them is the first deployment decision. In Autopilot mode, Google manages the nodes: it provisions, scales, and secures them, applies hardening defaults, and bills you for the CPU, memory, and storage your Pods request rather than for the nodes themselves. You focus on your workloads. In Standard mode, you configure and manage the node pools yourself — machine types, node counts, autoscaling settings, and node configuration — which gives you control over things Autopilot does not allow, such as custom node images, specific machine types, or node-level customization. Autopilot is the recommended default for most workloads, and the exam treats it as the better answer unless the scenario explicitly needs node-level control.
Cluster configuration options
Beyond the mode, clusters vary along a few axes the exam tests. A zonal cluster has its control plane and nodes in a single zone — cheaper, but a zone failure takes the cluster down. A regional cluster replicates the control plane across three zones in a region and can spread nodes across them — higher availability and the right choice for production. A private cluster keeps nodes without external IP addresses, so they are not reachable from the internet; the control plane endpoint can also be private, with access through a VPN or authorized networks. Private clusters are the answer whenever a question emphasizes that nodes must not be internet-accessible. GKE Enterprise (formerly Anthos) extends GKE with fleet management across multiple clusters and environments, including on-premises — the exam guide mentions it, but for ACE purposes it is enough to know it exists for multi-cluster management.
Clusters are created with gcloud container clusters create (or in the console), and you connect to a cluster with gcloud container clusters get-credentials, which writes the cluster's connection details into your kubeconfig file so that kubectl, the Kubernetes command-line tool, can talk to it. Installing kubectl is part of the exam guide: on most systems it comes with the Google Cloud CLI (gcloud components install kubectl), or it can be installed standalone.
Deploying a containerized application
Deploying an application to GKE means writing Kubernetes manifests — YAML files that describe what should run — and applying them with kubectl. The core objects are:
| Object | What it does |
|---|---|
| Pod | The smallest deployable unit: one or more containers sharing storage and networking |
| Deployment | Manages a set of identical Pods: replicas, rolling updates, rollbacks |
| Service | A stable network endpoint for a set of Pods (ClusterIP, NodePort, or LoadBalancer) |
| ConfigMap / Secret | Configuration and sensitive data injected into Pods without baking them into images |
| Namespace | A virtual cluster partition for isolating teams or environments |
The typical flow is: build a container image, push it to Artifact Registry (Google's container registry — Container Registry is its deprecated predecessor), write a Deployment manifest referencing the image, apply it with kubectl apply -f deployment.yaml, and expose it with a Service. A Service of type LoadBalancer provisions a Google Cloud load balancer with an external IP; a ClusterIP Service is reachable only inside the cluster. The exam tests this flow at a practical level: which command deploys the application, which Service type exposes it publicly, and where the image lives.
Images and Artifact Registry
Container images for GKE are stored in Artifact Registry, Google's registry for container images and other artifacts. GKE nodes pull images from Artifact Registry using the nodes' service account, which needs the Artifact Registry Reader role on the repository. A common deployment failure is an image-pull error caused by missing permissions on the repository — the fix is an IAM grant, not a cluster change. Images are tagged (for example, my-app:v1.2), and best practice is to deploy by specific tag or digest rather than latest, so that rollbacks are precise and deployments are reproducible. The exam guide mentions configuring GKE to access Artifact Registry under operations; for deployment purposes, remember that the image must exist in a registry the cluster can reach before the Deployment can start its Pods.
Workload types beyond Deployments
Deployments manage stateless, interchangeable Pods — the most common case — but Kubernetes has workload types for other shapes of application, and the exam guide mentions them under operations. A StatefulSet manages Pods that need stable network identities and stable persistent storage: each Pod gets a predictable hostname (such as db-0, db-1) and its own PersistentVolumeClaim, which survives restarts. StatefulSets are the right choice for databases and other stateful services running in a cluster. A DaemonSet ensures one Pod runs on every node in the cluster (or on a selected subset) — the pattern for node-level agents such as log collectors, monitoring agents, and network plugins. A Job runs a Pod to completion once, and a CronJob runs a Job on a schedule — the Kubernetes equivalent of a batch task or a nightly report. The exam tests the mapping: a logging agent on every node is a DaemonSet; a database with stable storage is a StatefulSet; a scheduled cleanup task is a CronJob; a stateless web service is a Deployment.
Cluster upgrades and maintenance
GKE clusters need periodic upgrades: new Kubernetes versions bring security fixes and features, and Google manages the control plane upgrade automatically (or on a schedule you choose), while node upgrades are your responsibility in Standard mode and Google's in Autopilot. In Standard mode, you upgrade a node pool by creating a new pool with the target version and migrating workloads, or by using the automated node upgrade feature, which replaces nodes gradually. Maintenance windows let you control when automatic upgrades and maintenance happen, so they do not land during a peak trading period. Release channels (Rapid, Regular, Stable) control how quickly a cluster receives new versions: Rapid gets features first, Stable gets them last after longer testing. For production clusters, the Regular or Stable channel with a maintenance window is the sensible choice. The exam rarely goes deep on upgrades, but it does test the principle that the control plane and the nodes are upgraded separately, and that node upgrades replace nodes rather than patching them in place.
Exam traps to watch for
- Using GKE Standard when the scenario does not need node control: Autopilot is the simpler, recommended default.
- Deploying a zonal cluster for a production workload that must survive a zone failure: use a regional cluster.
- Forgetting get-credentials: kubectl cannot talk to a cluster until the cluster credentials are in your kubeconfig.
- Using the deprecated Container Registry in new designs: Artifact Registry is the current registry.
Practice questions
Test yourself on this guide. Answers are checked instantly, with a full explanation for each question.
Q1.A team wants to deploy a containerized application to Kubernetes without managing nodes, and wants to be billed for the resources their Pods request. Which GKE mode should they choose?
Explanation: Autopilot removes node management entirely and bills for the CPU, memory, and ephemeral storage requested by Pods — matching both requirements. Standard mode requires managing node pools and bills for the nodes. A zonal cluster describes availability scope, not the management mode. GKE Enterprise is for multi-cluster fleet management, not for avoiding node management.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — deploying a GKE cluster with different configurations (Autopilot)
Q2.After creating a GKE cluster, a developer runs kubectl get pods and receives an error that no cluster is configured. What should they do?
Explanation: kubectl talks to a cluster using credentials stored in the kubeconfig file, and get-credentials writes those details for the named cluster. Reinstalling the CLI does not configure cluster access. A new cluster would have the same problem. The API must already be enabled, since the cluster was created successfully.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — installing and configuring the CLI for Kubernetes (kubectl)
Q3.A production application on GKE must remain available if a zone fails. Which cluster configuration should you choose?
Explanation: A regional cluster replicates the control plane across three zones and can spread nodes across them, so a zone failure does not take the cluster down. Zonal clusters — private, Autopilot, or with multiple node pools — keep everything in one zone and fail with it. Autopilot and private describe management mode and networking, not availability scope.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — deploying a GKE cluster with different configurations (regional clusters)
Q4.A security policy requires that GKE cluster nodes have no external IP addresses and are not reachable from the internet. Which cluster type meets this requirement?
Explanation: Private clusters provision nodes without external IP addresses, so they are not reachable from the internet; the control plane endpoint can also be private. Regional and zonal describe availability scope, not networking. Autopilot describes who manages the nodes, not whether they have external IPs.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — deploying a GKE cluster with different configurations (private clusters)
Q5.A developer has written a Kubernetes Deployment manifest for an application. Which command applies it to the cluster?
Explanation: kubectl apply -f applies a manifest file to the cluster, creating or updating the resources it describes. gcloud container clusters create creates a cluster, not a workload. kubectl run creates a single Pod imperatively and does not take a manifest file. gcloud run deploy deploys to Cloud Run, not GKE.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — deploying a containerized application to GKE
Q6.Pods in a GKE cluster fail to start with an image-pull error (ImagePullBackOff). The image exists in Artifact Registry. What is the most likely cause?
Explanation: Nodes pull images using their service account, and that account needs Artifact Registry Reader permission on the repository — without it, the pull fails even though the image exists. A private cluster can still pull images (through Private Service Connect or NAT) and would not produce this specific error pattern. A missing Service affects networking, not image pulling. The Kubernetes version is unrelated to registry permissions.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — deploying a containerized application to GKE
Q7.A team wants to expose a web application running in GKE to internet users. Which Kubernetes Service type should they use?
Explanation: A Service of type LoadBalancer provisions a Google Cloud load balancer with an external IP that forwards traffic to the Pods. ClusterIP is only reachable inside the cluster. NodePort exposes a port on each node but does not provide a load balancer or a stable external endpoint. Pods are not reachable from the internet by default — they need a Service to be exposed.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — deploying a containerized application to GKE
Q8.A team needs to manage a fleet of GKE clusters across multiple projects and environments, with centralized policy and configuration. Which offering is designed for this?
Explanation: GKE Enterprise (formerly Anthos) is Google's platform for managing fleets of clusters across projects, regions, and environments, with centralized policy and config management. A regional cluster is one cluster spanning zones, not a fleet tool. Cloud Run is a serverless container platform, not a cluster manager. Namespaces partition a single cluster; they do not manage multiple clusters.
Exam objective: ACE exam guide 2.1: Planning and implementing compute resources — deploying a GKE cluster with different configurations (GKE Enterprise)