Skip to content

Creating the cluster

None of the how-tos we found covered the creation of the initial Kubernetes cluster, because this is really down to the choice of hosting environment and appetite for cost. We created a standard cluster in GKE with the following cost-saving caveats:

  • As tempting as it sounds from an ease of management perspective, do NOT create an AutoPilot cluster. The minimum vCPU and Memory requests for an AutoPilot cluster will bankrupt you before you start (roughly $200/month!).
  • Use spot VMs for the nodes on which your cluster will be deployed. They offer significant cost savings over standard VMs and allow you to use decent-sized machines for your nodes at a fraction of the cost. We chose the e2-medium shared core machines and set the cluster to auto-scale from 0 to 3 nodes. You will want to make sure to set a Pod Disruption Budget (PDB) to make sure that auto-updating and pre-emption of the Spot VM nodes doesn't disrupt your instance services. We took the advice given here to set maxSurge=1 maxUnavailable=0.
  • Start with the smallest cluster available. You can always add more and beefier nodes to it later.


You will need to make sure you create your cluster with Workload Identity enabled. Authenticated access from the cluster service account (which is NOT an IAM service account) to other GCP services such as Cloud Storage depends on it.

Last update: February 3, 2023