As we all know, last year was the year of containers (such as Dockers and Kubernetes). You can think of these as methods that package an application's code so that it can be run with its dependencies, isolated from other processes. There are two main types of containers, that is, stateful containers and stateless containers. In stateless containers, data generated from one application will not be available for another application. Stateful containers, on the other hand, will store or record the data somewhere, so that it is available. In real-world applications, it is likely that we need to use stateful containers, based on our application's requirements.
Let's see the steps behind sharing the disk storage among containers. In this example, we will use a Kubernetes pod named PacktPod. This pod will contain two...