【Docker】exec: "docker-proxy": executable file not found in $PATH
头一次使用docker 找了一个镜像docker.io/skiychan/nginx-php7 打算部署容器。
于是开始执行:
sudo docker run --name nginx -p 8080:80 -d skiychan/nginx-php7
提示内容如下
ARN[0025] Failed to allocate and map port 8080-8080: exec: "docker-proxy": executable file not found in $PATHERRO[0026] Handler for POST /v1.26/containers/nginx/start returned error: driver failed programming external connectivity on endpoint nginx (ea9b65d1a1a18b7b1c1869141a9005c5bf71501edea5b5c27ba37f4047147d7c): exec: "docker-proxy": executable file not found in $PATH
Error response from daemon: driver failed programming external connectivity on endpoint nginx (ea9b65d1a1a18b7b1c1869141a9005c5bf71501edea5b5c27ba37f4047147d7c): exec: "docker-proxy": executable file not found in $PATH
Error: failed to start containers: nginx
看提示是缺少docker-prxoy这个可执行文件,而且端口分配失败,容器也启动失败。
但我每次执行 docker start nginx 的时候却输出:
WARN[0031] Failed to allocate and map port 8080-8080: Bind for 0.0.0.0:8080 failed: port is already allocatedERRO[0031] Handler for POST /v1.26/containers/nginx/start returned error: driver failed programming external connectivity on endpoint nginx (5c4718d32721fe466a9b400216913898eb8b7909f1ce73188e8db360cb55ff19): Bind for 0.0.0.0:8080 failed: port is already allocated
Error response from daemon: driver failed programming external connectivity on endpoint nginx (5c4718d32721fe466a9b400216913898eb8b7909f1ce73188e8db360cb55ff19): Bind for 0.0.0.0:8080 failed: port is already allocated
Error: failed to start containers: nginx
看样子端口已经分配了,但容器还是启动失败的样子。
求解如何使用docker,docker是yum安装在centos上的 版本号为:1.13.1。
回答
一样的问题
whereis docker-proxy
docker-proxy: /usr/bin/docker-proxy
软连接或者配置到path里面,试一下。
我看这个目录里有这几个可执行文件 是否是需要在/usr/bin 下面建立软连接?
以上是 【Docker】exec: "docker-proxy": executable file not found in $PATH 的全部内容, 来源链接: utcz.com/a/78275.html