Designed for SysAdmins, Operations staff, Developers, and DevOps, this book will introduce you to the open source container platform Docker.
In this book, we will walk you through installing, deploying, managing, and extend Docker. We're going to do that by first introducing you to the basics of Docker and its components. Then we'll start to use Docker to build containers and services to perform a variety of tasks.
We're going to take you through the development lifecycle, from testing to production, and see where Docker fits in and how it can make your life easier. We'll make use of Docker to build test environments for new projects, demonstrate how to integrate Docker with continuous integration workflow, and then how to build application services and platforms. Finally, we'll show you how to use Docker's API and how to extend Docker yourself.
We'll teach you how to:
* Install Docker.
* Take your first steps with a Docker container.
* Build Docker images.
* Manage and share Docker images.
* Run and manage more complex Docker containers.
* Deploy Docker containers as part of your testing pipeline.
* Build multi-container applications and environments.
* Learn about orchestration. Use Compose and Swarm for the orchestration of Docker containers and Consul for service discovery.
* Explore the Docker API.
* Getting Help and Extending Docker.
Table of Contents
The Docker Book
- 0.1 Who is this book for?
- 0.2 A note about versions
- 0.3 Credits and Acknowledgments
- 0.4 Technical Reviewers
- 0.5 Technical Illustrator
- 0.6 Proofreader
- 0.7 Author
- 0.8 Conventions in the book
- 0.9 Code and Examples
- 0.10 Colophon
- 0.11 Errata
- 0.12 Version
- 1.1 Introducing Docker
- 1.2 Docker components
- 1.3 What can you use Docker for?
- 1.4 Docker with configuration management
- 1.5 Docker’s technical components Docker’s technical components
- 1.6 What’s in the book? What’s in the book?
- 1.7 Docker resources
2 Installing Docker
- 2.1 Requirements
- 2.2 Installing on Ubuntu and Debian
- 2.3 Installing on Red Hat and family
- 2.4 Docker for Mac
- 2.5 Docker for Windows installation
- 2.6 Using Docker on OSX and Windows with this book
- 2.7 Docker installation script
- 2.8 Binary installation
- 2.9 The Docker daemon
- 2.10 Upgrading Docker
- 2.11 Docker user interfaces
- 2.12 Summary
3 Getting Started with Docker
- 3.1 Ensuring Docker is ready
- 3.2 Running our first container
- 3.3 Working with our first container
- 3.4 Container naming
- 3.5 Starting a stopped container
- 3.6 Attaching to a container
- 3.7 Creating daemonized containers
- 3.8 Seeing what’s happening inside our container Seeing what’s happening inside our container
- 3.9 Docker log drivers
- 3.10 Inspecting the container’s processes Inspecting the container’s processes
- 3.11 Docker statistics
- 3.12 Running a process inside an already running container
- 3.13 Stopping a daemonized container
- 3.14 Automatic container restarts
- 3.15 Finding out more about our container
- 3.16 Deleting a container
- 3.17 Summary
4 Working with Docker images and repositories
- 4.1 What is a Docker image?
- 4.2 Listing Docker images
- 4.3 Pulling images
- 4.4 Searching for images
4.5 Building our own images
- 4.5.1 Creating a Docker Hub account
- 4.5.2 Using Docker commit to create images
- 4.5.3 Building images with a Dockerfile
- 4.5.4 Building the image from our Dockerfile
- 4.5.5 What happens if an instruction fails?
- 4.5.6 Dockerfiles and the build cache
- 4.5.7 Using the build cache for templating
- 4.5.8 Viewing our new image
- 4.5.9 Launching a container from our new image
- 4.5.10 Dockerfile instructions
- 4.6 Pushing images to the Docker Hub
- 4.7 Deleting an image
- 4.8 Running your own Docker registry
- 4.9 Alternative Indexes
- 4.10 Summary
5 Testing with Docker
- 5.1 Using Docker to test a static website
- 5.2 Using Docker to build and test a web application
- 5.3 Using Docker for continuous integration
- 5.4 Multi-configuration Jenkins
- 5.5 Other alternatives
- 5.6 Summary
6 Building services with Docker
- 6.1 Building our first application
- 6.2 Building a Java application server with Docker
- 6.3 A multi-container application stack
- 6.4 Managing Docker containers without SSH
- 6.5 Summary
7 Docker Orchestration and Service Discovery
- 7.1 Docker Compose
- 7.2 Consul, Service Discovery and Docker
- 7.3 Docker Swarm
- 7.4 Orchestration alternatives and components
- 7.5 Summary
8 Using the Docker API
- 8.1 The Docker APIs
- 8.2 First steps with the Engine API
- 8.3 Testing the Docker Engine API
- 8.4 Improving the TProv application
- 8.5 Authenticating the Docker Engine API
- 8.6 Summary
9 Getting help and extending Docker
- 9.1 Getting help
- 9.2 Reporting issues for Docker
- 9.3 Setting up a build environment
- 9.4 Summary
- Title: The Docker Book
- Release date: July 2014
- Publisher(s): Turnbull Press
- ISBN: None