setting up kubernetes cluster and running a database

9/19/2020

kubernetes cluster

This is my proposed kubernetes cluster, I want to be able to run Postgresql database, with my nodes accessing storage machine for storing the data, is this using NFS a good option? How best can I run a database instance here?

-- tinashe.chipomho
kubernetes
kubernetes-cluster
kubernetes-pod
postgresql

1 Answer

9/24/2020

I recommend you to use helm chart for deploying any kind of data base, it is very handy and easy to deploy, visit the link: https://github.com/bitnami/charts/tree/master/bitnami/postgresql

Any way if you want to deploy Postgresql, first of all you need to create persistent volume(pv) and persistent volume claim(pvc), because you choosed NFS for your cluster storage solution. You have to manually create your pv and pvc.

But kubernetes has storage class solution too, it is better to use some kubernetes volume plugin with internal provisioner like glusterfs or cephfs.

https://kubernetes.io/docs/concepts/storage/storage-classes/

-- mhafshari
Source: StackOverflow