4 Pods

 

This chapter covers

  • An introduction to pods
  • Managing multiple containers within a Pod
  • Using Volumes with Pods

Podman stands for Pod Manager. Pod is a concept popularized by the Kubernetes project, It is a group of one or more containers working together for a common purpose and sharing the same namespaces and cgroups (resource constraints). Additionally, Podman ensures that on SELinux machines all container processes within a pod share the same SELinux labels, this means that they can all work together from an SELinux point of view.

4.1 Running Pods

Podman pods, just like Kubernetes pods, always include a container called the infra container, sometimes called the pause container (not to be confused with the rootless pause container, mentioned in section 5.2). The infra container only holds open the namespaces and cgroups from the kernel, allowing containers to come and go within the pod. When Podman adds a container to a pod, it adds the container process to the cgroups and namespaces. Notice that the infra container has a conmon process monitoring it,also every container within a pod has its own conmon.

Figure 4.1 Podman pod launches conmon with the infra container, which will hold cgroups and linux namespaces.
Note

The infra container (pause container) is similar to the rootless pause container while its only purpose is to hold open the namespaces and cgroups while containers come and go. But each Pod will have a different infra container.

4.1.1 Creating a pod

4.1.2 Adding a container to a pod

4.1.3 Starting a pod

4.1.4 Stopping a pod

4.1.5 Listing pods

4.1.6 Removing pods

4.2 Summary

sitemap