11: Docker Networking
It’s always the network!
Any time there’s an infrastructure problem, we always blame the network. Part of the reason is that networks are at the center of everything — no network, no app!
In the early days of Docker, networking was hard. These days, it’s almost a pleasure ;-)
In this chapter, we’ll look at the fundamentals of Docker networking. Things like the Container Network Model (CNM) and libnetwork
. We’ll also get our hands dirty building and testing networks.
As usual, we’ll split the chapter into three parts:
- The TLDR
- The deep dive
- The commands
Docker Networking - The TLDR
Docker runs applications inside of containers, and applications need to communicate with other application. Some of these other applications are containers and some aren’t. This means Docker needs strong networking capabilities.
Fortunately, Docker has solutions for container-to-container networks, as well as connecting...