Linux 安装Docker运行环境
Debian 安装Docker运行环境
curl -sSL https://get.docker.com | sh
# Install required packages
apt update
apt install -y python python-pip
# Install Docker Compose from pip
pip install docker-compose
在root用户下粘贴下面命令即可安装docker运行环境
第一步黏贴:
apt-get -y install \
apt-transport-https \
ca-certificates \
curl \
gnupg2 \
software-properties-common
第二步黏贴(本步骤需要科学上网):
curl -fsSL https://download.docker.com/linux/debian/gpg | apt-key add -
apt-key fingerprint 0EBFCD88
add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/debian \
$(lsb_release -cs) \
stable"
第三步黏贴:
apt-get -y update
apt-get -y install docker-ce
apt-get -y install docker-compose
第四步黏贴:
curl -L https://github.com/docker/compose/releases/download/1.23.2/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose