Deploy CouchDB Database on GKE using Helm
Let us create a CouchDB database using Helm and ROBIN Storage. In the Cloud Shell Run the following command in the Cloud Shell. This command will install CouchDB cluster as a StatefulSet. We are setting the storageClass to robin-0-3 to benefit from data management capabilities ROBIN Storage brings.
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 CouchDB database.
Get Service IP address of our CouchDB database:
Get admin user and password of our CouchDB from Kubernetes Secret:
Adding data to the CouchDB database
Let us load data into our CouchDB database. Let us create a database robindb:
Let’s create document employees under database robindb and add 5 records to it:
After adding document, we should see the following :
We have now deployed a CouchDB database on GKE with some sample data.
To benefit from data management capabilities ROBIN brings, such as taking snapshots, making clones, and creating backups, we have to register this CouchDB Helm release as an application with ROBIN.
Registering the Helm release as an application
To benefit from the data management capabilities, we’ll register our CouchDB database with ROBIN. Doing so will let ROBIN map and track all resources associated with the Helm release for this CouchDB app. To register the Helm release as an application, run the following command:
Let’s verify ROBIN is now tracking our CouchDB Helm release as a single entity (app).
You should see an output similar to this.
We have successfully registered our Helm release as an app called “couch”. Let us check the status on the app:
The output should look like this.
This concludes the Deploy CouchDB on GKE tutorial. Now that we have deployed the CouchDB database, loaded data, and registered the CouchDB Helm release with ROBIN Storage, we can create a CouchDB database snapshot and create a CouchDB clone that includes the app plus data.