Programster's Blog

Tutorials focusing on Linux, programming, and open-source

Install Docker Compose

After installing Docker, you may also want to install Docker Compose. This tool allows you to manage applications that rely on multiple containers instead of just one.

This tutorial assumes you are running Debian 8 or Ubuntu 16.04.

Native Packages

On Ubuntu 18.04, you can install docker-compose by simply running:

sudo apt-get install docker-compose -y

This will install an older version than the PIP method, but should get the job done. I found this caused strange issues when building docker images in Ubuntu 18.04 so went back to using PIP.

Using PIP

You can use this method to install the latest version of docker-compose on Debian 8+ and Ubuntu 16.04+ distributions.

sudo apt-get install python-pip -y
sudo pip install --upgrade pip
sudo pip install docker-compose

Check Version

To test that you have successfully installed docker compose, run the following command:

docker-compose --version