ssh-keygen -t rsa -C "your-pc-tag"
把 id_rsa.pub
文件中的内容拷贝到另一台服务器的 authorized_keys
文件中。
sudo yum remove docker \
docker-common \
docker-selinux \
docker-engine
sudo yum install -y yum-utils \
device-mapper-persistent-data \
lvm2
sudo yum-config-manager \
--add-repo \
https://download.docker.com/linux/centos/docker-ce.repo
sudo yum install docker-ce
sudo systemctl start docker
sudo systemctl enable docker
拷贝到服务器后,移动到 /usr/local/bin/
目录
添加可执行权限
sudo chmod +x /usr/local/bin/docker-compose
docker rmi $(docker images -f "dangling=true" -q)