dockerdocker-compose

Installing docker-compose-plugin on amazon linux 2


I'm trying to install docker-compose-plugin onto Amazon Linux 2, so that "docker compose" acts more like "docker-compose" would. [As I understand, the latter is deprecated] I can't find any instructions and the obvious approach (treat it like Centos 7) does not work at all - the basic way docker is installed on Amazon Linux 2 is very different.

Does anybody know?


Solution

  • Here is a bash script to install latest docker compose plugin for all users on amazon linux 2:

    sudo mkdir -p /usr/local/lib/docker/cli-plugins/
    sudo curl -SL https://github.com/docker/compose/releases/latest/download/docker-compose-linux-x86_64 -o /usr/local/lib/docker/cli-plugins/docker-compose
    sudo chmod +x /usr/local/lib/docker/cli-plugins/docker-compose