How to install docker-compose in EC2

Compose is a tool for defining and running multi-container Docker applications. With Compose, we need to use a Compose file to configure your application's services.

This article explains the steps to install docker-compose command in EC2 instance. We can follow the same procedure to install docker-compose in any Linux systems.

Step1: Login to the server as root via ssh.

Step2: Download the command file.

#curl -L https://github.com/docker/compose/releases/download/1.21.0/docker-compose-`uname -s`-`uname -m` | sudo tee /usr/local/bin/docker-compose > /dev/null

Step3: Assign the execute permission.

#chmod +x /usr/local/bin/docker-compose

Step4: Create a link in the system binary location.

#ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose

That's all…

Leave a Reply

Your email address will not be published. Required fields are marked *