大部分教程安装docker compose都是从github下载的,速度太慢,解决办法就是换源

curl -L https://get.daocloud.io/docker/compose/releases/download/1.25.5/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose

然后修改目录权限可执行,不然后续docker-compose up命令会报错

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

查看安装是否成功

docker-compose -v