docer安装

1、一键安装

curl -sSL https://get.docker.com/ | sh systemctl start docker systemctl enable docker.service
systemctl start docker && systemctl enable docker.service
2、配置加速

cat << EOF > /etc/docker/daemon.json
{
"registry-mirrors": [
"https://registry.cn-hangzhou.aliyuncs.com",
"https://docker.mirrors.ustc.edu.cn",
"https://registry.docker-cn.com",
"http://hub-mirror.c.163.com",
"https://docker.mirrors.ustc.edu.cn"
],
#"insecure-registries":["192.168.1.10:5000"],
"exec-opts": ["native.cgroupdriver=systemd"],
"log-driver": "json-file",
"log-opts": {
"max-size": "100m"
},
"storage-driver": "overlay2",
"storage-opts": [
"overlay2.override_kernel_check=true"
]
}
EOF

posted @ 2021-02-22 15:20  海浪的声音  阅读(118)  评论(0)    收藏  举报