【linux】debian使用二进制文件安装docker

下载二进制包

wget https://download.docker.com/linux/static/stable/x86_64/docker-18.06.3-ce.tgz

解压

tar xzvf docker-18.06.3-ce.tgz

复制二进制文件到/usr/bin目录下

cp docker/* /usr/bin/

检查是否安装

docker version

配置 docker.service文件

vim /lib/systemd/system/docker.service

写入如下内容

[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com
After=network-online.target firewalld.service
Wants=network-online.target

[Service]
Type=notify
ExecStart=/usr/bin/dockerd
ExecReload=/bin/kill -s HUP $MAINPID
LimitNOFILE=infinity
LimitNPROC=infinity
TimeoutStartSec=0
Delegate=yes
KillMode=process
Restart=on-failure
StartLimitBurst=3
StartLimitInterval=60s

[Install]
WantedBy=multi-user.target

启动dockerd服务进程

systemctl daemon-reload
systemctl start docker.service

检验

ps aux|grep docker

你可能感兴趣的:(linux)