Ubuntn系统下安装的docker;
apt更新了{sudo apt update},wget也安装了{sudo apt install wget},ssh服务也安装了{sudo apt install ssh};centos也安装了{docker pull centos};
使用dockefile文件时出错了;dockerfile文件内容:
FROM centos
MAINTAINER Yi.Ma <findlymw@gmail.com>
RUN yum -y update
RUN yum install -y passwd openssh-server openssh-clients initscripts net-tool
RUN yum install python-setuptools -y
RUN easy_install superviso
RUN echo 'root:root' | chpasswd
RUN /usr/sbin/sshd-keygen
EXPOSE 22
CMD /usr/sbin/sshd -D
使用root用户切换到对应的目录下面执行:docker build ‐t yi/centos7‐ssh . 命令时报错;报错信息如下:
root@ubuntu:/home/bcl/envdm/jichu/centos7# docker build -t yi/centos7-ssh .
Sending build context to Docker daemon 3.584kB
Step 1/10 : FROM centos
---> 0f3e07c0138f
Step 2/10 : MAINTAINER Yi.Ma <findlymw@gmail.com>
---> Using cache
---> f02274e5139b
Step 3/10 : RUN yum -y update
---> Using cache
---> 5cfa834cb327
Step 4/10 : RUN yum install -y passwd openssh-server openssh-clients initscripts net-tool
---> Running in e80b8930d2ee
Last metadata expiration check: 14:06:22 ago on Fri Oct 11 12:20:20 2019.
No match for argument: net-tool
Error: Unable to find a match
The command '/bin/sh -c yum install -y passwd openssh-server openssh-clients initscripts net-tool' returned a non-zero code: 1
docker新手,不懂参数不匹配是什么意思;该用什么参数;从哪找
相似问题