Google Game Servers Game Services Game Server Cluster

This page shows how to write Terraform for Game Servers Game Services Game Server Cluster and write them securely.

google_game_services_game_server_cluster (Terraform)

The Game Services Game Server Cluster in Game Servers can be configured in Terraform with the resource name google_game_services_game_server_cluster. The following sections describe 2 examples of how to use the resource and its parameters.

Example Usage from GitHub

main.tf#L7
resource "google_game_services_game_server_cluster" "this" {
  cluster_id  = var.cluster_id
  description = var.description
  labels      = var.labels
  location    = var.location
  project     = var.project
game_server.tf#L1
resource "google_game_services_game_server_cluster" "default" {
  provider   = google-beta

  cluster_id = ""
  realm_id = 1234

Review your Terraform file for Google best practices

Shisho Cloud, our free checker to make sure your Terraform configuration follows best practices, is available (beta).

Parameters

Required. The resource name of the game server cluster

Human readable description of the cluster.

  • id optional computed - string
  • labels optional - map from string to string

The labels associated with this game server cluster. Each label is a key-value pair.

Location of the Cluster.

  • name optional computed - string

The resource id of the game server cluster, eg: 'projects/[project_id]/locations/[location]/realms/[realm_id]/gameServerClusters/[cluster_id]'. For example, 'projects/my-project/locations/[location]/realms/zanzibar/gameServerClusters/my-onprem-cluster'.

The realm id of the game server realm.

  • connection_info list block

    Namespace designated on the game server cluster where the game server instances will be created. The namespace existence will be validated during creation.

    • gke_cluster_reference list block

      The full or partial name of a GKE cluster, using one of the following forms: 'projects/[project_id]/locations/[location]/clusters/[cluster_id]' 'locations/[location]/clusters/[cluster_id]' * '[cluster_id]' If project and location are not specified, the project and location of the GameServerCluster resource are used to generate the full name of the GKE cluster.

  • timeouts single block

Explanation in Terraform Registry

A game server cluster resource. To get more information about GameServerCluster, see:

Frequently asked questions

What is Google Game Servers Game Services Game Server Cluster?

Google Game Servers Game Services Game Server Cluster is a resource for Game Servers of Google Cloud Platform. Settings can be wrote in Terraform.

Where can I find the example code for the Google Game Servers Game Services Game Server Cluster?

For Terraform, the niveklabs/google and roger-beathard/simple-tf-policy-tool source code examples are useful. See the Terraform Example section for further details.

security-icon

Automate config file reviews on your commits

Fix issues in your infrastructure as code with auto-generated patches.