Docker build source code installed Nginx error

docker build source When installing Nginx, there is a step ./configure build docker build has been unable to go, try to. / Configure write script, nor line.

  Root @ docker01: / data / nginx / centos-nginx # docker build -t nginx-1.29-centos. 
Sending build context to Docker daemon 3.072 kB
Sending build context to Docker daemon
Step 0: FROM centos: 7.1.1503
---> f1dade627e25
Step 1: MAINTAINER LINCOLN ZHONG
---> Using cache
---> 31ad459daf5e
Step 2: RUN yum install -y gcc-c ++
---> Using cache
---> 28debfed95c5
Step 3: RUN yum-y install zlib zlib-devel openssl openssl - devel pcre pcre-devel
---> Using cache
---> 0b4a2ae64d13
Step 4: RUN yum install-y tar
---> Using cache
---> 6fece9fc67ed
Step 5: RUN yum install -y wget
---> Using cache
---> ff33bf1aa164
Step 6: RUN cd /
---> Using cache
---> ed10ae3a67c0
Step 7: RUN wget http://nginx.org/download/nginx-1.2.9.tar.gz
---> Using cache
---> ecc3c0d7960c
Step 8: RUN tar zxvf nginx-1.2.9.tar.gz -C / usr / sbin
---> Using cache
---> 677838fd45f7
Step 9: RUN cd /usr/sbin/nginx-1.2.9/
---> Using cache
---> fefa79499ce0
Step 10: RUN ./configure
---> Running in 2e79135f23db
***** / bin / sh: ./configure: No such file or directory
The command '/ bin / sh -c ./configure' returned a non-zero code: 127 *****

2015-07-20 add comment share it

  • Weibo
  • QZONE
  • Micro letter

Did not find the relevant results

    Invited:

    Tuxknight

    Agree from: lincoln_alex


    Try using WORKDIR, or use the absolute path of configure

    Heads up! This alert needs your attention, but it's not super important.