报错如下:
container_linux.go:247: starting container process caused "exec: "/bin/sh": stat /bin/sh: no such file or directory"
Dockerfile内容如下:
FROM tiangolo/uwsgi-nginx:latest
MAINTAINER Sebastian Ramirez <tiangolo@gmail.com>
# Add app configuration to Nginx
COPY nginx.conf /etc/nginx/conf.d/
# install redis and start
COPY redis-install.sh /tmp/
RUN chmod +x /tmp/redis-install.sh
RUN /bin/sh /tmp/redis-install.sh
COPY startserver.sh /tmp/
RUN chmod +x /tmp/startserver.sh
# install mongodb
# Create the MongoDB data directory
RUN mkdir -p /data/db
# Import MongoDB public GPG key AND create a MongoDB list file
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10
RUN echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | tee /etc/apt/sources.list.d/10gen.list
# Update apt-get sources AND install MongoDB
RUN apt-get update
RUN apt-get install -y -q mongodb-org ; echo 'after'
COPY requirement.txt /tmp/
RUN pip install -r /tmp/requirement.txt
ENTRYPOINT ["/bin/bash"]
执行docker build -t debug . 的时候发现的
不知道哪里出错了 希望各位大咖帮忙看看
能贴完整的报错信息吗,你这一句报错是 docker run 这个容器的时候改成/bin/bash
RUN /bin/sh /tmp/redis-install.sh
这一句指令中调用了/bin/sh,但是你的基础镜像中应该是没有这个文件的。建议检查基础镜像或更换基础镜像