docker常用排错及知识点

2023-12-28 12:01:38

docker常用排错及知识点

停止docker

systemctl stop docker

启动docker

systemctl start docker

重启docker

systemctl restart docker

查看docker状态

systemctl status docker

docker开启2375端口

/lib/systemd/system/docker.service文件中,

ExecStart=/usr/bin/dockerd后添加:

-H tcp://0.0.0.0:2375 -H unix:///var/run/docker.sock

docker配置文件

配置文件位置:/etc/docker/daemon.json

{
  “max-concurrent-downloads”: 10,
  "insecure-registries": [],
  "log-driver": "json-file",
  "log-opts":{
    "max-size": "500m",
    "max-file": "3"
  }
  "storage-opts": [],
  "max-concurrent-uploads": 10,
  "storage-driver": "overlay2",
  "hosts": [
    "unix:///var/run/docker.sock"
  ],
  "default-ulimits": {},
  "ipv6": false
}

文章来源:https://blog.csdn.net/qq_45591903/article/details/135202956
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。