Use Docker Compose To Share An Entire Application

Joel Lord
InstructorJoel Lord

Share this video with your friends

Send Tweet

Now that you have three containers ready to be used, you will learn how to create a docker-compose.yaml file. By using Docker Compose, you will be able to share a single YAML file and anyone will be able to run your application.

Docker-compose is part of the Docker tools suite and is an application that will take a YAML file to start all of your containers with one single command.

Using Compose is basically a three-step process:

  1. Define your app’s environment with a Dockerfile so it can be reproduced anywhere.
  2. Define the services that make up your app in docker-compose.yml so they can be run together in an isolated environment.
  3. Run docker-compose up and Compose starts and runs your applications.

Compose works in all environments: production, staging, development, and testing.