当我尝试使用docker build -t opencv:2.4.11 .
命令构建docker镜像时,出现以下错误。
Sending build context to Docker daemon 189.8 MB
Step 1 : FROM ubuntu:trusty
---> b72889fa879c
Step 2 : RUN apt-get update
---> Running in 689f34e138c2
Container command '/bin/sh' could not be invoked.
我的Docker客户端和服务器版本为:
Client:
Version: 1.11.0
API version: 1.23
Go version: go1.5.4
Git commit: 4dc5990
Built: Wed Apr 13 18:34:23 2016
OS/Arch: linux/amd64
Server:
Version: 1.11.0
API version: 1.23
Go version: go1.5.4
Git commit: 4dc5990
Built: Wed Apr 13 18:34:23 2016
OS/Arch: linux/amd64
任何的想法?
我已将
/var/lib/docker
目录软链接(soft link)到家中存在的目录之一。该目录由root拥有。这是问题的根源吗?在移动和软链接(soft link)之前,还不错。我的根分区空间不足,因此必须将其更改为我的主分区。
我的主分区是
ext4
文件系统。问候
最佳答案
看起来胶管不好。
我建议修改守护程序参数以改为包括-g your_other_directory
。然后停止并重新启动Docker。
如果仍然无法使用,请删除两个Docker目录,重新安装,然后再次从-g
步骤开始。
关于docker - Docker:找不到容器命令 '/bin/sh',我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/36691315/