What are the steps for installing docker-compose on Ubuntu?
The steps to install Docker Compose on Ubuntu are as follows:
- Firstly, make sure that Docker is already installed. If Docker has not been installed yet, please follow the official documentation to install Docker: https://docs.docker.com/engine/install/ubuntu/
- Use the following command to download the latest version of Docker Compose:
sudo curl -L "https://github.com/docker/compose/releases/latest/download/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
- Grant execution permission:
sudo chmod +x /usr/local/bin/docker-compose
- The directory where executable files are located
sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose
- Verify if the installation was successful.
docker-compose --version
If the version number of Docker Compose is displayed, it means the installation was successful.
You have now successfully installed Docker Compose on Ubuntu.