环境问题
交互式启动容器(-it),进入容器后可以执行安装的软件(以perl为例),但是通过 -i 运行容器找不到安装的软件。 启动容器时不会运行bash 文件,需要将软件链接到 Usr/bin 中。
通过 -it运行示例如下1
2
3
4 docker run -v /home/gedongcen/WDL/:/home/gedongcen/WDL/ -it aio_dev:1.0.0.0
进入环境
root@caf48909e8b5[Wed Feb 08]$ perl -v
This is perl 5, version 22, subversion 0 (v5.22.0) built for x86_64-linux-thread-multi
通过 -i 运行示例如下1
2
3
4
5 docker run -v /home/gedongcen/WDL/:/home/gedongcen/WDL/ -i aio_dev:1.0.0.0 perl -v
docker: Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "perl": executable file not found in $PATH: unknown.
docker run -v /home/gedongcen/WDL/:/home/gedongcen/WDL/ -i aio_dev:1.0.0.0 /bin/bash perl -v
/bin/bash: perl: No such file or directory