Learn How to Deploy with Docker Compose the Right Way

Do you need to:

  • Get your head around Docker Compose quickly?
  • Dockerize existing applications to make them easier to deploy?
  • Reduce the time required for developers to get started on projects?
  • Learn how to debug an existing Docker Compose-based app?

Then this free book and course are for you!

It's a hands-on, step-by-step guide to Docker Compose that teaches you all you need to know, without wasting your time with unnecessary detail. By the time you're finished you be able to dockerize an application and deploy it to a remote environment, plus so much more.

Get Your Copy Today!

And join over 500 others who have already downloaded it.

Please correct the following error(s):
  • {{ error }}

I'll email you with regular updates on the course's progress, so that you know how it's progressing and when it goes live as well, as well as tips, tricks, and things worth knowing about Docker and the wider Docker ecosystem. You can unsubscribe at any time. Here's the privacy policy.

The front cover of Deploy With Docker Compose - The Essentials

Why Get The Book and Course?

I can think of a number of reasons to get the book, but here are some of the best:

  • You like to know the essentials of deploying with Docker Compose and the related commands and files, so that you’re not completely dependent on your DevOps team or sys admins.
  • You don’t see yourself as a DevOps person nor a systems administrator, so you’d prefer to stick to what you know.
  • You don’t want to spend the countless hours — or have them to spare — that I spent, working out the essentials of deploying applications with Docker Compose yourself.
  • You're keen to build your application and get it deployed, as you, like so many other developers, have a constant stream of requests for new features, and for fixes to existing features that you need to get finished.

But more specifically, here’s why you should get the book and course because you want:

  • To learn a logical and intuitive, 6-step process you can use to deploy your applications to production; a process that is repeatable and applicable to a broad range of applications.
  • To know the essential Docker Compose commands and files required, so that you can learn about the myriad of others at some time in the future.
  • A straight-forward deployment process that you can test before you use it to deploy applications to production.
  • A solid and practical foundation of how to deploy with Docker Compose – that you can learn and apply quickly – yet you can build on, as and when you need to later on.
  • To learn some extra knowledge about developing with Docker Compose, such as how to run your unit tests and debug your applications when their running inside containers, regardless of whether those containers are running on a local or remote host.
  • And quite a bit more…

What You'll Learn

Docker Compose's Essential Terminology

Before you dive into creating a local development environment using Docker Compose, you'll learn some essential terminology that you need to be aware of, terms such as Image, Container, and Registry.

How to Install Docker Compose

Now that you know some of the key terminology, it's time to install Docker Compose and the related tools that you'll need to follow along with the book and course. In this chapter, you'll learn how to do that on the three major operating systems: Linux, macOS, and Microsoft Windows.

How to Build a Local Development Environment using Docker Compose

In this chapter, you're going to get your hands dirty with Docker Compose by learning how to build a development environment which serves as the basis for production (or any other environment).

You're going to learn the essentials of Dockerfiles and Docker Compose files (docker-compose.yml) to build a 3-service configuration that can run an application on your local development machine. On top of that, you're going to learn the essential Docker and Docker Compose commands for starting and stopping containers and testing that they're running properly.

How to Perform Basic Docker Compose Debugging

Now that you've learned how to create a basic setup with Docker Compose, you're going to learn how to do basic container debugging. If things go wrong, you need to know how to figure out what’s going wrong and why.

With that knowledge, you can either fix the problem or ask someone for help if you’re unable to fix it on your own. So in this chapter, you're going to learn the Docker commands to debug containers.

How to Run Tests and Debug Apps When They're Run Using Docker Compose

Docker and Docker Compose make it pretty trivial to build local development environments. But what about running tests and debugging applications running inside containers, versus on your local development machine?

How do you run unit, functional, acceptance, and other types of tests when the code and runtime are inside Docker containers, not on your local machine? How do you do step-through debugging?

In this chapter, I'll show you how to augment the configuration which we've built so far, to do both. Specifically, I'll show you how to run tests using PHPUnit and Codeception and to do step-through debugging using PhpStorm. In future editions of the book, I may expand this chapter to include other languages, such as Java or Python.

How to Deploy Apps to Production Using Docker Compose and a Handful of Docker Commands

In the final chapter of the book, you'll learn how to build Dockerfiles and Docker Compose files to deploy applications to a remote environment. You'll also learn some of the things that you need to consider when deploying containers to remote environments, versus on your local development machine.

You’ll also learn about building, tagging, and pushing Docker images to image registries, and how to create Docker contexts so that you can work with multiple remote Docker daemons. It won't make you a DevOps guru or Systems Administrator — but you'll be that much less reliant on them!

Your presentation was great.
I'm glad we got to do this!

Profile picture from Shelley Benhoff
Shelley Benhoff Author @Pluralsight & @Docker Community Leader.


Why are the Book and Course Free?

It might seem a little too good to be true, that a professional book and course on Docker are free. But, I can assure you that they both are, and that there is nothing shady going on. The book and course are free for several reasons:

  • I use Docker on a regular basis and have gained so much by doing so.
  • I see many others struggling as I did, when I first started using Docker. I want to help them avoid the mistakes that I made and come up to speed with Docker quicker and easier than I did. Consequently, I see a huge need for a book and course like this and believe that they will help become as comfortable using Docker as I am.
  • I want to give back to the community that helped me learn Docker over the last number of years.
  • Finally, the book and course are a thank you to everyone who has bought my books or taken my premium courses.

While I've spent over 200 hours on Learn How to Deploy with Docker Compose the Right Way so far, enough people enjoy my teaching style and continue learning with one of my books or premium courses. So, it all works out for all of us in the end! That said, you can support the project, if you'd like; I'd be very grateful if you do.

What formats is the book available in?

At the moment, the book is only available in PDF format. However, it may be available in ePub and Mobi formats in the future.

Do I need any special tools to follow the book and course?

Nothing very much at all, actually. Just the following things:

  • Git
  • A cloned copy of the book’s code, or an application you want to deploy using Docker Compose
  • A text editor or IDE of your choosing. I have no particular preference but recommend VIM and PhpStorm (as I do most of my development in PHP)

The book and course step through installing Docker Engine, Docker Desktop, and Docker Compose.

I have a question about the book and/or course, can I email you?

Sure can! Email me anytime: matthew[at]webdevwithmatt.com.

I lost, deleted, or never received my welcome email! What do I do?

Some people have told me that that has been happening. Email me anytime at matthew[at]webdevwithmatt.com. I'll get you sorted.

I found a typo or bug with the book

Whether it's in the book or site, email me at matthew[at]webdevwithmatt.com.

Can I re-distribute the book and charge money for it?

Erm, no.

Who's the Author?

Hi, I'm Matthew Setter. I've been developing web-based applications since 1996 and developing with PHP since version 3 — way back in 1999 before it even had OOP support. I've been involved in building all kinds of PHP-based applications in Australia, the United Kingdom, and Germany. I'm also a PHP editor in the Twilio Voices team. I regularly share what I know and am continuing to learn about PHP and web development more broadly on my site: Web Dev with Matt

Connect with me

Want to Listen to the Deploy with Docker Compose Talk?

If you're not sure if the book is for you, come and listen to me give a talk, based on the book, and see what you think. The talk's titled "Deploying PHP Apps with Docker Compose - The Essentials". Yes, it does have an emphasis on PHP, but that's because most of my experience is with PHP. The approach that the book and talk cover can be applied regardless of the language that your application is developed with.

DM me on Twitter or email me and let's work out a time and date.