Skip to main content
This guide walks you through deploying a Restate cluster on Kubernetes using the Restate Operator. We will use kind to create a local Kubernetes cluster for testing purposes.
1

Prerequisites

Install the following on your local machine:This guide was written with kind v0.30.0, Restate Operator v1.8.1, and Restate v1.5.0. Contact us on Discord or Slack if something does not work as expected.
2

Create a kind cluster

Set kubectl context to kind-kind:
3

Install the Restate Operator

Install the Restate Operator via Helm:
To install the operator, you need permission to create namespaces and CRDs.
4

Create a Restate cluster

Create a RestateCluster manifest in a file called restate-cluster.yaml:
restate-cluster.yaml
Note that we disable network policies here for simplicity, but in a production environment, you should configure appropriate network policies for security.To learn more about the RestateCluster spec options, see the RestateCluster pkl definition.Apply the manifest:
A single-node Restate deployment will be created in the restate-test namespace.Wait until the restate-0 pod is in the Ready state:
5

Forward the ports of the Restate ingress and the UI to your local machine

Now you can access the Restate UI at http://localhost:9070.
6

Build and upload a Restate service Docker image to the kind cluster

For example, download the TypeScript Hello World service:
Build a Docker image for the service:
Upload the image to the kind cluster:
7

Deploy the Restate service

Create a RestateDeployment manifest for the service in a file called service-deployment.yaml:
service-deployment.yaml
Apply the manifest to deploy the service:
You should now see the deployed service listed in the Restate UI:
The Restate Operator automatically registered the service with the Restate cluster.
8

Invoke the service

In the Restate UI playground, you can now invoke the service. In the overview page, click on the greet handler of your service to open the playground. Then send a request:
9

🎉 You did it!

You have successfully deployed a Restate cluster and a Restate service on a local kind Kubernetes cluster using the Restate Operator!Check out the Restate Operator docs for further information.
After you are done experimenting, you can delete the kind cluster: