OpenShift, containers, microservices, pods... so many buzzwords, so little clarity. What do these terms mean and how do they relate to each other? In today's post we will try to give you an overview on the functionality of container platforms.
Imagine that: We are PHP applications and live, together with many other applications, in a big estate. In fact, though, we would much rather be alone. But where, and how to find a suitable place to call your own? That's exactly what the so-called "Bureau for Containers" is for, which is provided by a company called Docker. Its friendly bureaucrats enable applications to live their lives independently from others. For this purpose, they kindly provide us with a container, which is equipped according to our needs.
The house is to be understood in this context as a server. Normally a server hosts several applications, such as a Tomcat app server, an Apache web server or a MySQL database. The disadvantage is that they all use different libraries in different versions and can get in each other's way. To avoid this problem, we use containers with Docker.
Okay, so the Bureau has provided us with a container. But it is - unfortunately - not responsible for keeping it clean, nor for enabling us to communicate with other containers. Luckily, the property management company called Kubernetes takes care of this. Our requests, as well as the requests from all other applications, are received by Kubernetes and are handled automatically. To this end, the administrators move our container into a pod which is then placed into a sort of "residential complex".
Kubernetes is there to manage the Docker containers. Kubernetes is the control application for OpenShift, so to speak. All the settings we set up are implemented by Kubernetes. To do so, Kubernetes puts the containers into so-called Pods. Once the container is in a pod, it is allowed to communicate with the Kubernetes network. The so-called k8s services will be in charge of the individual tasks.
Since we live alone in our Pod now, it gets pretty lonely after a while. Therefore, we ask the administration if it is possible to get a like-minded web app as a neighbour. The administration responds, it is indeed possible to get an exact copy of ourselves. Perfect! They immediately contact the service provider "Replication Controller" and request a clone of our Pod. Lonesome no more!
Replication Controllers are also responsible for creating multiple clones of the Pods (=pod replicas) if the workload is too high. This is done automatically, using the autoscaler. It is of course also possible to determine the number of clones manually.
With this simplified presentation I hope to have given you a basic understanding of how OpenShift works. How such a container solution is set up, has been discussed in a recent blog post: