Posts

Showing posts from November, 2020

Persistent Volume Example in Kubernetes - Stateful Application

Image
Welcome back on Kubernetes tutorial series. In today's tutorial , we will talk about using persistent volumes in kubernetes and a quick demo of setting up persistent volume on your local machine. Persistent volumes are useful for stateful application development where you always keep record of last information processed or maintain database transactional status.  We all know by default if your Pod re-starts then you loose current status of your application which may not be applicable in every scenario. In this example, we will provision PersistentVolume(PV) and PersistentVolumeClaim using default Storage class provisioned by hostPath. There are multiple types of Storage classes supported by Kubernetes. Complete list can be found by below link. https://kubernetes.io/docs/concepts/storage/storage-classes/ Github Location :  https://github.com/shashivish/kubernetes-example/tree/master/pvc-example Pre-requisite : Minikube Cluster On a high level , we will be following below task in th