CentOS 安装 docker-compose

490人浏览 / 0人评论
# 方法一 (Refer to: https://docs.docker.com/compose/install/)
sudo curl -L "https://github.com/docker/compose/releases/download/v2.2.3/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose

# 方法二 (Refer to: https://docs.docker.com/compose/install/#install-using-pip)
sudo pip3 install docker-compose
# 测试
docker-compose --version

# 方法二补充
yum install yum-utils -y
yum-config-manager --add-repo https://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo
pip3 install --upgrade pip
pip3 install docker-compose

全部评论