Chapter 3. Installing Docker

We’re now at the point where you hopefully understand roughly what Docker is and what it isn’t, and it’s time for some hands-on work. Let’s get Docker installed so we can work with it. The steps required to install Docker vary depending on the platform you use for development and the Linux distribution you use to host your applications in production.

In this chapter, we discuss the steps required to get a fully working Docker development environment set up on most modern desktop operating systems. First we’ll install the Docker client on your native development platform, and then we’ll get a Docker server running on Linux. Finally, we’ll test out the installation to make sure it works as expected.

Although the Docker client can run on Windows and macOS to control a Docker server, Linux containers can be built and launched only on a Linux system.1 Therefore, non-Linux systems will require a virtual machine or remote server to host the Linux-based Docker server. Docker Community Edition, Docker Machine, and Vagrant, which are all discussed later in this chapter, provide some approaches to address this issue. It is also possible to run Windows containers natively on Windows systems, and we will specifically discuss this in “Windows Containers”, but most of the book’s focus will be on Linux containers.

Note

The Docker ecosystem is changing very rapidly as the technology evolves to become more robust and solve a broader range of problems. Some features ...

Get Docker: Up & Running, 2nd Edition 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.