Jump to Content
Containers & Kubernetes

Run your game infrastructure on GKE Autopilot to focus on player experience

March 21, 2023
Ishan Sharma

Senior Product Manager, Google Kubernetes Engine

Earlier this month, we shared Google Cloud's strategy for live service games which outlines our focus on the three critical pillars of (1) serving players everywhere, (2) collecting and organizing game data, and (3) unlocking player and game insights. Starting today, you can run your game workloads on Google Kubernetes Engine (GKE) Autopilot — a truly automated experience in running global multiplayer game servers. This blog explores how GKE Autopilot can help you serve players globally.  

For players, games just have to work. Game developers must have underlying cloud infrastructure that is simple to operate and seamlessly scales with player traffic, so that game developers can focus on what truly matters: building great games. At Google Cloud, we are fixated on making game launches boring by making GKE Autopilot the platform-of-choice for running game workloads for scalability, reliability, and automation. 

One of the most critical components of a multiplayer game is the dedicated game server — an authoritative source of game state to which players' clients connect to interact with the game world. These dedicated game servers have to stay up during a game session, handle many connections, and scale based on metrics such as concurrent players.

https://storage.googleapis.com/gweb-cloudblog-publish/images/Global_Scale_Architecture_-_GKE_Autopilot_.max-1400x1400.jpg
Example architecture of a global scale game

Now you can run dedicated game servers on GKE Autopilot using Agones, an open source game server orchestrator that we have been developing with the games industry. When running game servers on GKE Autopilot, Google Cloud manages the clusters for you, and you only pay for the CPU, memory, and storage that your game servers request while running. You don’t pay for unallocated nodes or system overhead, regardless of how your game servers are scheduled. 

"We use Google Kubernetes Engine to run our dedicated games servers and we are sensitive to the operating costs of clusters. We are excited to run our game servers using GKE Autopilot with Agones because it eliminates the need to manage Kubernetes node pools helping us scale our game servers and our team without scaling our costs."Hiroki Awata, Software Engineer, DeNA

Power-up: Game servers on GKE Autopilot 

To get started with GKE Autopilot for games, first create a GKE Autopilot cluster, then create a firewall rule to allow UDP player traffic, and install Agones using Helm.

Loading...

Since GKE Autopilot is Kubernetes, we can create a game server fleet with the same fleet configuration yaml that we apply to any Kubernetes cluster.

Loading...

Notice how we didn’t have to think about the number of nodes, node pools, or cluster autoscaler configuration we would need to run our game servers: we simply defined the number of game servers we wanted to run. Wasn’t that easy?

For the win: Hands-off infrastructure

GKE Autopilot is perfect for running your dedicated game servers because it is a hands-off, fully-managed Kubernetes platform that manages your cluster’s underlying infrastructure without you needing to configure or monitor - a workload level SLA backed by Google SRE. By using Agones FleetAutoscaler with GKE Autopilot, your global game server fleets automatically and dynamically scale as players flow in and out of your game - you can set it and forget it!

Loading...

With traditional Kubernetes, this scaling requires resources and time for planning, right-sizing, and bin-packing. You might overprovision node pools much earlier in anticipation of scaling up and keep those node pools running longer before scaling down. All this costs money. 

Scaling game servers with GKE Autopilot makes sense because game servers are pods and Autopilot speaks in units of pods. Autopilot ensures you pay only for your running game server pods and you don’t pay for system components, operating system overhead, or unallocated capacity. According to a Forrester study, using GKE Autopilot results in up to 85% reduction in infrastructure costs and 45% improvement in developer efficiency.

noclip On: Full control, full freedom

Fully managed doesn’t have to mean vendor lock-in. Some game companies on Google Cloud run their games on cluster fleets that span across regions, on-premises, or other cloud vendors. Since Agones is open source and GKE Autopilot is based on open source Kubernetes, when serving your games with GKE Autopilot you don’t have to sacrifice portability or flexibility. Better yet, Google Cloud continues to be the largest contributor to both the Agones and Kubernetes projects allowing you to leverage our expertise and help define the roadmap to serve the next generation of games.

Pro-move: Leverage the integrations with the best of Google Cloud

The technology needed for successfully running global multiplayer games extends beyond dedicated game servers and includes matchmaking services, custom network proxies, databases, and analytics. When running game servers on GKE, these integrations are easy. For example, you can use Open Match on GKE Autopilot to scale the matchmaker with your dedicated game servers or manage player data with Cloud Spanner.

Secret Mission: Continuous delivery with Google Cloud Deploy multi-target parallel deployment

Let’s say that you want to launch your game server with new features for an upcoming global game event, region-by-region. Cloud Deploy’s new multi-target deployment capability enables you to do just that. Create GKE clusters in the regions your players are close to, group them (as targets) into multi-targets, and deploy your Agones game servers in waves. Need to first validate in a staging environment? No problem, create a staging target at the start of your progression sequence. Need an approval pause button before deployment to production? Cloud Deploy supports that too, along with multi-target rollback.

https://storage.googleapis.com/gweb-cloudblog-publish/images/IMG02-agones_clouddeploy_blog_032023.max-1900x1900.jpg
A Cloud Deploy delivery pipeline progression sequence using multi-targets

Game on

We understand that every resource that you have to spend on managing and scaling infrastructure is one less resource spent on making great games. To get started with running game servers on GKE Autopilot, learn more.

Posted in