O'Reilly logo
live online training icon Live Online training

Docker: Beyond the Basics (CI & CD)

Continuous integration and continuous deployment

Topic: System Administration
Sean Kane

Once you are comfortable with Docker basics (what it is and how it works), the next step is to dive into Docker tools and services for continuous integration (CI) and continuous deployment (CD). Through a mix of lecture and hands-on exercises, Sean Kane walks you through container image management with Docker Distribution, continuous integration using Jenkins with Docker, and using Docker Swarm for building Docker clusters with simple orchestration. In just two three-hour sessions, you’ll move beyond Docker fundamentals and learn how to streamline your processes and make your development and deployment workflows smoother, repeatable, and automated.

What you'll learn-and how you can apply it

By the end of this live, online course, you’ll understand:

  • What Docker Compose is for and how to use it
  • What Docker Distribution is and how to use it
  • What Docker Swarm is and how to use it
  • How Docker can be used to streamline continuous integration

And you’ll be able to:

  • Set up a private Docker registry with Docker Distribution
  • Set up a Jenkins-based continuous integration pipeline in Docker
  • Utilize Docker Swarm to build robust Docker cluster orchestration

This training course is for you because...

  • You’re a software engineer who wants to use Docker to streamline your software delivery pipeline, use Jenkins with Docker to automate your testing pipeline, and deploy your containers in scalable production clusters.
  • You’re an operations engineer who wants to learn how to use Docker Swarm for creating Docker clusters for deploying and managing containers.
  • You’re a team leader who wants to see how your organization and team can use Docker to improve your DevOps efforts, standardize and streamline your software processes, and free up your engineers to focus on business goals.


Please follow the Pre-Class setup steps fully detailed in the link below: https://gist.github.com/spkane/401f2d9ba6576d7d2ab1b25d8b1a9d11

  • A solid understanding of how to build and run custom Docker containers
  • A working knowledge of the Unix command line (useful but not required)

Required materials and setup:

  • A computer with root/admin rights and sufficient resources to run three virtual machines (CPU virtualization extensions must be enabled in your BIOS/EFI.)
  • The text editor of your choice (Instructor recommends Atom).
  • Recent computer and operating system
  • Windows, Linux, or OS X - Tested on Windows 10 and OS X 10.12
  • Sufficient resources to run 1 virtual machine
  • Reliable and fast internet connectivity
  • Git client
  • KVM/xhyve/HyperV (or other VM technology)
  • Docker Community Edition for Mac/Windows
  • Docker Engine and Docker Compose for Linux
  • Docker should already be installed and tested on your laptop

Recommended Preparation:

The Docker Video Collection (video)

Docker: Up and Running (book)

About your instructor

  • Sean Kane is a lead site reliability engineer at New Relic. He's had a long career in production operations, with many diverse roles across a broad range of industries. Sean is the lead inventor on a container-related patent and spends a lot of his spare time writing, teaching, and speaking about modern production operations. He is an avid traveler, hiker, and camper and lives in the US Pacific Northwest with his wife, children, and dogs.


The timeframes are only estimates and may vary according to how the class is progressing

Day One

Overview and course setup (40 minutes)

  • Lecture: A quick overview of Linux containers, Docker, and Docker Machine
  • Hands-on exercise: Launch and test your Docker virtual machine

Docker Compose (30 minutes)

  • Lecture: The purpose of Docker Compose; the components of a Docker Compose project file
  • Hands-on exercise: Modify, deploy, and test a multicontainer Docker Compose project

Break (5 minutes)

Docker Distribution (40 minutes)

  • Lecture: Image repositories and what they do
  • Hands-on exercise: Configure, deploy, and test Docker Distribution

Break (5 minutes)

Jenkins: Part 1 (65 minutes)

  • Lecture: An overview of the testing tools ecosystem; an overview of Jenkins and how it can be used with Docker; the Jenkins UI, how it works, and what Jenkins plugins the project relies on
  • Hands-on exercise: Download and launch the Jenkins Docker Compose project and follow along and with your individual Jenkins instance

Day Two

Jenkins: Part 2 (85 minutes)

  • Lecture: A review of the previous day; an overview of the Docker-based project that you are going to build and test via Jenkins; the components and wiring needed to build a basic CI flow; an exploration of a broken build and how to use the CI workflow to automatically detect this after the code is committed

  • Hands-on exercise: Using the Jenkins Docker Compose project from Day One, piece together the individual steps of a CI flow; build off a working code branch and test the resulting Docker container; change to a Git branch with a broken commit and try to build your project; after an in-class review of your project, commit a bug fix to the project and then resubmit your code to the CI flow

Break (10 minutes)

Docker Swarm (95 minutes)

  • Lecture: An overview of the orchestration tools ecosystem; an overview of Docker Swarm and the various scheduling algorithms and constraints available; how to perform rolling updates and draining a node; load balancing, using HAProxy to provide VIPs for your services, and Clair security scanning; an overview of managing secrets with Docker Swarm

  • Hands-on exercise: Start two additional virtual machines and create a Swarm cluster; utilize Jenkins to deploy a working build to your Swarm cluster; inspect, scale, and then delete your service; modify Jenkins to deploy your service via a rolling update; modify your service to utilize secrets in Swarm

Wrap-up and Q&A (10 minutes)