Skip to content
This repository has been archived by the owner on Feb 16, 2022. It is now read-only.

Error while building Docker image #32

Closed
muellermartin opened this issue Jun 28, 2017 · 2 comments
Closed

Error while building Docker image #32

muellermartin opened this issue Jun 28, 2017 · 2 comments

Comments

@muellermartin
Copy link
Contributor

Running docker build -t matrix . in the repository folder fails with following error:

Sending build context to Docker daemon 20.48 kB
Step 1/16 : FROM debian:jessie
 ---> 62a932a5c143
Step 2/16 : MAINTAINER Silvio Fricke <silvio.fricke@gmail.com>
 ---> Using cache
 ---> f98040fdf4cf
Step 3/16 : COPY adds/start.sh /start.sh
 ---> Using cache
 ---> 9c6984af9e5c
Step 4/16 : COPY adds/supervisord-matrix.conf /conf/
 ---> Using cache
 ---> 191442ed940f
Step 5/16 : COPY adds/supervisord-turnserver.conf /conf/
 ---> Using cache
 ---> 25e1d38a8478
Step 6/16 : COPY adds/supervisord.conf /
 ---> Using cache
 ---> 2453dd65e66a
Step 7/16 : ENTRYPOINT /start.sh
 ---> Using cache
 ---> 5f81f938be08
Step 8/16 : CMD start
 ---> Using cache
 ---> 66f89c23b266
Step 9/16 : EXPOSE 8448
 ---> Using cache
 ---> 75eefc8bbf1f
Step 10/16 : VOLUME /data
 ---> Using cache
 ---> 53942db5f088
Step 11/16 : ARG BV_SYN=master
 ---> Using cache
 ---> cb0a66ffc205
Step 12/16 : ARG BV_TUR=master
 ---> Using cache
 ---> bae8b3e0eafa
Step 13/16 : ENV LIBRARY_PATH /lib:/usr/lib
 ---> Using cache
 ---> 4106173d0a26
Step 14/16 : ENV MATRIX_UID 991 MATRIX_GID 991
 ---> Using cache
 ---> d29e4910cc0b
Step 15/16 : ARG REBUILD=1
 ---> Using cache
 ---> 3d295b467510
Step 16/16 : RUN set -ex     && mkdir /uploads     && export DEBIAN_FRONTEND=noninteractive     && touch /var/cache/apt/archives/lock     && apt-get clean     && apt-get update -y     && apt-get upgrade -y     && apt-get install -y         bash         coreutils         coturn         file         gcc         git         libevent-2.0-5         libevent-dev         libffi-dev         libffi6         libgnutls28-dev         libjpeg62-turbo         libjpeg62-turbo-dev         libldap-2.4-2         libldap2-dev         libsasl2-dev         libsqlite3-dev         libssl-dev         libssl1.0.0         libtool         libxml2         libxml2-dev         libxslt1-dev         libxslt1.1         linux-headers-amd64         make         pwgen         python         python-dev         python-pip         python-psycopg2         python-virtualenv         sqlite         zlib1g         zlib1g-dev     ;     pip install --upgrade pip ;    pip install --upgrade python-ldap ;    pip install --upgrade lxml ;    pip install --upgrade supervisor     ;     git clone --branch $BV_SYN --depth 1 https://github.com/matrix-org/synapse.git     && cd /synapse     && pip install --upgrade --process-dependency-links .     && GIT_SYN=$(git ls-remote https://github.com/matrix-org/synapse $BV_SYN | cut -f 1)     && echo "synapse: $BV_SYN ($GIT_SYN)" >> /synapse.version     && cd /     && rm -rf /synapse     ;     apt-get autoremove -y         file         gcc         git         libevent-dev         libffi-dev         libjpeg62-turbo-dev         libldap2-dev         libsqlite3-dev         libssl-dev         libtool         libxml2-dev         libxslt1-dev         linux-headers-amd64         make         python-dev         zlib1g-dev     ;     apt-get autoremove -y ;    rm -rf /var/lib/apt/* /var/cache/apt/*
 ---> Running in 66a65e63279b
+ mkdir /uploads
+ export DEBIAN_FRONTEND=noninteractive
+ touch /var/cache/apt/archives/lock
touch: cannot touch '/var/cache/apt/archives/lock': No such file or directory
+ pip install --upgrade pip
/bin/sh: 1: pip: not found
The command '/bin/sh -c set -ex     && mkdir /uploads     && export DEBIAN_FRONTEND=noninteractive     && touch /var/cache/apt/archives/lock     && apt-get clean     && apt-get update -y     && apt-get upgrade -y     && apt-get install -y         bash         coreutils         coturn         file         gcc         git         libevent-2.0-5         libevent-dev         libffi-dev         libffi6         libgnutls28-dev         libjpeg62-turbo         libjpeg62-turbo-dev         libldap-2.4-2         libldap2-dev         libsasl2-dev         libsqlite3-dev         libssl-dev         libssl1.0.0         libtool         libxml2         libxml2-dev         libxslt1-dev         libxslt1.1         linux-headers-amd64         make         pwgen         python         python-dev         python-pip         python-psycopg2         python-virtualenv         sqlite         zlib1g         zlib1g-dev     ;     pip install --upgrade pip ;    pip install --upgrade python-ldap ;    pip install --upgrade lxml ;    pip install --upgrade supervisor     ;     git clone --branch $BV_SYN --depth 1 https://github.com/matrix-org/synapse.git     && cd /synapse     && pip install --upgrade --process-dependency-links .     && GIT_SYN=$(git ls-remote https://github.com/matrix-org/synapse $BV_SYN | cut -f 1)     && echo "synapse: $BV_SYN ($GIT_SYN)" >> /synapse.version     && cd /     && rm -rf /synapse     ;     apt-get autoremove -y         file         gcc         git         libevent-dev         libffi-dev         libjpeg62-turbo-dev         libldap2-dev         libsqlite3-dev         libssl-dev         libtool         libxml2-dev         libxslt1-dev         linux-headers-amd64         make         python-dev         zlib1g-dev     ;     apt-get autoremove -y ;    rm -rf /var/lib/apt/* /var/cache/apt/*' returned a non-zero code: 127

I could fix this by inserting following lines after && export DEBIAN_FRONTEND=noninteractive \ (line 34):

    && mkdir -p /var/cache/apt/archives \
    && touch /var/cache/apt/archives/lock \

Additional information:

  • docker --version: Docker version 17.03.1-ce, build c6d412e
  • OS: macOS 10.12.5 (Sierra)
@muellermartin
Copy link
Contributor Author

muellermartin commented Jun 28, 2017

I will create a pull request as a fix for this issue shortly.

Edit: Created PR #33 to possibly fix this issue.

muellermartin added a commit to muellermartin/docker-matrix that referenced this issue Jun 28, 2017
silvio added a commit that referenced this issue Jun 28, 2017
Fix issue #32: Add missing lock file for apt
@silvio
Copy link
Owner

silvio commented Jun 28, 2017

Thanks for your error report and the commit.

Please use next time the github related keywords described here.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants