O'Reilly logo

Docker: Up & Running by Sean P. Kane, Karl Matthias

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 6. Exploring Docker

Now that we have some experience working with Docker containers and images, we can explore some of its other capabilities. In this chapter, we’ll continue to use the docker command-line tool to talk to the running docker daemon that you’ve configured, while visiting some of the other fundamental commands.

Docker provides commands to do a number of additional things easily:

  • Printing the Docker version

  • Viewing the server information

  • Downloading image updates

  • Inspecting containers

  • Entering a running container

  • Returning a result

  • Viewing logs

  • Monitoring statistics

Let’s take a look at some of those and some community tooling that augments Docker’s native capabilities.

Printing the Docker Version

If you completed the last chapter, you have a working Docker daemon on a Linux server or virtual machine, and you’ve started a base container to make sure it’s all working. If you haven’t set that up already and you want to try out the steps in the rest of the book, you’ll want to follow the installation steps in Chapter 3 before you move on with this section.

The absolute simplest thing you can do with Docker is print the versions of the various components. It might not sound like much, but this is a useful tool to have in your belt because the server and API are often not backwards compatible with older clients. Knowing how to show the version will help you troubleshoot certain types of connection issues. Note that this command actually talks ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required