大家好,又见面了,我是你们的朋友全栈君。
cd /usr/lib/systemd/system/ vim docker.service #在原本的ExecStart
中添加tcp://0.0.0.0:2375
[Service] Type=notify
# the default is not to use systemd for cgroups because the delegate issues still
# exists and systemd currently does not support the cgroup feature set required
# for containers run by docker
ExecStart=/usr/bin/dockerd -H tcp://0.0.0.0:2375 -H unix://var/run/docker.sock --containerd=/run/containerd/containerd.sock
ExecReload=/bin/kill -s HUP $MAINPID
TimeoutSec=0
RestartSec=2
Restart=always
systemctl daemon-reload systemctl restart docker.service
转载于:https://www.cnblogs.com/nhz-M/p/11150607.html
发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/132108.html原文链接:https://javaforall.net