Chapter 3. Containerizing Your Application: More Than Boxes

Over the past several years, containers have grown in popularity. Not only do they offer low overhead, high security, and high portability, they also follow best-practice cloud principles such as immutability, ephemerality, and autoscaling.

In this chapter, we’ll explain what containers are and discuss the popular containerization platforms. In addition, we’ll look past the general industry hype and explain why you might want to use containers. We’ll also highlight some of their benefits, especially when it comes to the cloud.

Why Containers?

Containers run on top of the host operating system and usually are orchestrated using software like Docker (as we’ll discuss later in this chapter) or Kubernetes (see Figure 3-1).

Figure 3-1. The container operating paradigm

One of the most important benefits of containers is that they provide virtual-machine-like isolation, but without the overhead of running an instance of the host operating system for each container. At scale, this can save a significant amount of system resources.

Isolation

Containers provide isolation via a number of methods in a flexible manner that is configured by the administrator. Containers can be isolated in the following ways:

System resources
Isolation is achieved via the CPU, memory, and disk cgroups.
Namespaces
Isolation is achieved by ...

Get Cloud Native Infrastructure with Azure now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.