vim /usr/lib/systemd/system/docker.service
ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock
改为
ExecStart=/usr/bin/dockerd -H tcp://0.0.0.0:2375 -H unix:///var/run/docker.sock -H fd:// --containerd=/run/containerd/containerd.sock
重启docker
systemctl daemon-reload && systemctl restart docker
安装portainer
docker run -itd --name=portainer -p 9000:9000 portainer/portainer
配置portainer
http://192.168.0.x:9000
填写
Username
Password(符合规范)
Confirm password
方法一:Local
Connect
如报错,使用方法二
Failure
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
Name:自己填写
Endpoint URL :192.168.0.x:2375 (docker ip port)
Connect
成功安装,可以使用
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)