yum -y install net-tools
yum -y install docker
service docker start
systemctl enable docker.service docker
一、 通过python按照 (centos7 有时安装不成功)
yum install python yum
yum -y install epel-release
pip install --upgrade pip
yum -y install python-pip
pip install docker-compose --ignore-installed requests
二、通过手工安装
访问https://github.com/docker/compose/releases,下载 docker-compose-Linux-x86_64,我是复制链接地址,在迅雷中下载的,下载后,将docker-compose-Linux-x86_64重命名为docker-compose
将刚才下载的docker-compose文件上传到centos7的/usr/local/bin/目录下
宝塔安装
yum install -y wget && wget -O install.sh http://download.bt.cn/install/install_6.0.sh && sh install.sh