官网地址
https://docs.docker.com/compose/install/#install-compose
安装高版本docker-compose
curl -L "https://github.com/docker/compose/releases/download/1.24.1/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
添加执行权限
chmod +x /usr/local/bin/docker-compose
Note: If the command docker-compose
fails after installation, check your path. You can also create a symbolic link to /usr/bin
or any other directory in your path.
sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose
再检查一下版本
docker-compose --version
卸载 2种方式
sudo rm /usr/local/bin/docker-compose
pip uninstall docker-compose