Let’s create an ElasticSearch database using Helm and ROBIN Storage. In the Cloud Shell run the following command. The command will install ElasticSearch in a three-master node configuration. We are setting the storageClass to robin-0-3 to benefit from data management capabilities ROBIN Storage brings.
Before proceeding, let us make sure all necessary workloads (pods) are running properly. Click on the “Workloads” tab on the left-hand panel, and wait for the status of all workloads to be shown as ”OK” with a green check next to them.
Let’s confirm that our Database is deployed and all relevant Kubernetes resources are ready.
You should be able to see an output showing the status of your ElasticSearch database.
Get the name of the client pod of your ElasticSearch database by running the following command.
Add an index called ‘test-index’ on the client pod. This is where we will add our data with the following command:
Adding data to the ElasticSearch database
Add a user named Bob to the test-index we created above.
Verify that a user named bob has been added to the database on the index we created by running the command:
You should see an output similar to the following:
We have now deployed an ElasticSearch database on GKE with a user named Bob added to our ElasticSearch database.
To benefit from data management capabilities ROBIN brings, such as taking snapshots, making clones, and creating backups, we have to register this ElasticSearch Helm release as an application with ROBIN.
Registering the ElasticSearch Helm release as an application
Registering this ElasticSearch Helm release as an application will enable ROBIN map and track all resources associated with the Helm release for this ElasticSearch database. To register the Helm release as an application, run the following command.
Let’s verify ROBIN is now tracking our ElasticSearch Helm release as a single entity (app) by running the following command.
You should see an output similar to this.
We have successfully registered our Helm release as an app called “myusers”.
This concludes the Deploy ElasticSearch on GKE tutorial. Now that we have deployed the ElasticSearch database, loaded data, and registered the ElasticSearch Helm release with ROBIN, we can create an ElasticSearch database snapshot and create an ElasticSearch clone including app plus data.