The original work is Laremere/space-agon.
Space Agon is a demo of Agones and Open Match. You can try integrations of Gaming OSS.
Warning: Be aware of billing charges for running the cluster.
Space Agon has been tested on this cluster size (nodes and machine types), but a small cluster may be sufficient for your use.
Don't leave the cluster running when you're not using it if you're concerned about cost. See pricing for more.
You need to install tools:
Google Cloud Shell has all tools you need.
LOCATION=us-central1
ZONE=$LOCATION-a
# Set Your Project ID before you run
PROJECT_ID=<your project id>
REPOSITORY=space-agon
gcloud services enable artifactregistry.googleapis.com \
container.googleapis.com
gcloud config set project $PROJECT_ID
gcloud config set compute/zone $ZONE
# Create cluster (using default network)
# Set NETWORK=<your network>, if you want to select the network
make gcloud-test-cluster
# Create Artifact Registry Repository
gcloud artifacts repositories create $REPOSITORY \
--repository-format=docker \
--location=$LOCATION
# Assign roles to default service account
gcloud projects add-iam-policy-binding $PROJECT_ID \
--member serviceAccount:$(gcloud iam service-accounts list \
--filter="displayName:Compute Engine default service account" \
--format="value(email)") \
--role roles/artifactregistry.reader
# Login Artifact Registry
gcloud auth configure-docker $LOCATION-docker.pkg.dev
# Install Agones
make agones-install
# Install Open Match
make openmatch-install
Make sure you installed docker to build and push images
# build space-agon images
make build
# apply space-agon images
make install
Get External IP from:
kubectl get service frontend
Open http://<external ip>/
in your favorite web browser. You can use "find
match" to start searching for a match.
Repeat in a second web browser window to create a second player, the players will be connected and can play each other.
View Running Game Servers:
kubectl get gameserver
Then use the connect to server option with the value <ip>:<port>
.
make uninstall
make agones-uninstall
make openmatch-uninstall
gcloud projects delete $PROJECT_ID
This is Apache 2.0 License.
This is not an officially supported Google product.