The problem?
As the number of applications grew, so did the complexity of managing all of these dependencies. Each machine had to be carefully configured to run all our applications, and that was incredibly hard to manage. We needed a way to provide a consistent and isolated environment for our applications.
Virtual Machines
We solved this problem with Virtual Machines (VM). Each application could have its own operating system, baked with the exact dependencies it needed, and that was great.
As our systems became more complex and the number of applications and services we had to run started to grow, even Virtual Machines were a bit too heavyweight. It was not viable to run an entire operating system for each small (or micro) service we had to deploy.
Docker
That’s when container technologies like Docker started to become popular. We can package our services in containers that will run on the same host operating system but still with enough isolation that we don’t need to worry about one container affecting the others. Even though Virtual Machines and containers are completely different things, they serve the same purpose for us in many ways. It provides an isolated and consistent environment to run our applications