jfloff / alpine-python

A small, more complete, Python Docker image based on Alpine Linux.
MIT License
481 stars 97 forks source link

currently (Nov 2016) creating child image is not possible because of conflict #7

Closed allan-simon closed 7 years ago

allan-simon commented 7 years ago

I got the following error: which seems caused by http://bugs.alpinelinux.org/issues/6375 (especially as the date of your last commit and the date of this bug seems related I wouldn't be precised if the issue has appeared a little after your last image push)

Step 7 : RUN /entrypoint.sh   -b git && echo
 ---> Running in 76aeceda709c
fetch http://dl-cdn.alpinelinux.org/alpine/v3.4/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz
ERROR: unsatisfiable constraints:
  musl-1.1.14-r12:
    breaks: musl-dev-1.1.14-r14[musl=1.1.14-r14]
    satisfies:
               musl-utils-1.1.14-r12[musl=1.1.14-r12]
               musl-utils-1.1.14-r12[so:libc.musl-x86_64.so.1]
               pkgconf-1.0.1-r0[so:libc.musl-x86_64.so.1]
               gcc-5.3.0-r0[so:libc.musl-x86_64.so.1]
               binutils-libs-2.26-r0[so:libc.musl-x86_64.so.1]
               libcrypto1.0-1.0.2j-r0[so:libc.musl-x86_64.so.1]
               g++-5.3.0-r0[so:libc.musl-x86_64.so.1]
               readline-6.3.008-r4[so:libc.musl-x86_64.so.1]
               sqlite-libs-3.15.0-r0[so:libc.musl-x86_64.so.1]
               mpfr3-3.1.2-r0[so:libc.musl-x86_64.so.1]
               ncurses-libs-6.0-r7[so:libc.musl-x86_64.so.1]
               python3-3.5.2-r4[so:libc.musl-x86_64.so.1]
               gdbm-1.12-r0[so:libc.musl-x86_64.so.1]
               libstdc++-5.3.0-r0[so:libc.musl-x86_64.so.1]
               libbz2-1.0.6-r5[so:libc.musl-x86_64.so.1]
               bash-4.3.46-r3[so:libc.musl-x86_64.so.1]
               isl-0.14.1-r0[so:libc.musl-x86_64.so.1]
               libcurl-7.51.0-r0[so:libc.musl-x86_64.so.1]
               mpc1-1.0.3-r0[so:libc.musl-x86_64.so.1]
               libressl2.4-libcrypto-2.4.3-r1[so:libc.musl-x86_64.so.1]
               git-2.8.3-r0[so:libc.musl-x86_64.so.1]
               pcre-8.38-r1[so:libc.musl-x86_64.so.1]
               libressl2.4-libssl-2.4.3-r1[so:libc.musl-x86_64.so.1]
               libffi-3.2.1-r2[so:libc.musl-x86_64.so.1]
               zlib-1.2.8-r2[so:libc.musl-x86_64.so.1]
               libgomp-5.3.0-r0[so:libc.musl-x86_64.so.1]
               apk-tools-2.6.7-r0[so:libc.musl-x86_64.so.1]
               libssh2-1.7.0-r0[so:libc.musl-x86_64.so.1]
               libgcc-5.3.0-r0[so:libc.musl-x86_64.so.1]
               make-4.1-r1[so:libc.musl-x86_64.so.1]
               alpine-baselayout-3.0.3-r0[so:libc.musl-x86_64.so.1]
               libatomic-5.3.0-r0[so:libc.musl-x86_64.so.1]
               xz-libs-5.2.2-r1[so:libc.musl-x86_64.so.1]
               ca-certificates-20160104-r6[so:libc.musl-x86_64.so.1]
               gmp-6.1.0-r0[so:libc.musl-x86_64.so.1]
               busybox-1.24.2-r11[so:libc.musl-x86_64.so.1]
               scanelf-1.1.6-r0[so:libc.musl-x86_64.so.1]
               libressl-2.4.3-r1[so:libc.musl-x86_64.so.1]
               expat-2.2.0-r0[so:libc.musl-x86_64.so.1]
               binutils-2.26-r0[so:libc.musl-x86_64.so.1]
               libssl1.0-1.0.2j-r0[so:libc.musl-x86_64.so.1]
  pkgconf-1.0.1-r0:
    conflicts: pkgconfig-0.25-r1[pkgconfig=1]
    satisfies: pkgconfig-0.25-r1[pkgconf]
               gcc-5.3.0-r0[pkgconfig]
               python3-dev-3.5.2-r4[pkgconfig]
  pkgconfig-0.25-r1:
    conflicts: pkgconf-1.0.1-r0
    satisfies: gcc-5.3.0-r0[pkgconfig]
               python3-dev-3.5.2-r4[pkgconfig]
The command '/bin/sh -c /entrypoint.sh   -b git && echo' returned a non-zero code: 47
jfloff commented 7 years ago

Could you tell me which image you were trying to build?

Thanks for the feedback!

allan-simon commented 7 years ago

I'm trying to build this dockerfile

FROM jfloff/alpine-python:latest-slim 
COPY requirements.txt /requirements.txt
COPY my-app/ /my-app
RUN cat /entrypoint.sh
RUN /entrypoint.sh \
 -b git \
&& echo
EXPOSE 8888
CMD ["python", "-m" , "cloudgate"
allan-simon commented 7 years ago

I've pulled the image just now, with the fix for the chmod +x :)

jfloff commented 7 years ago

You hit the nail right in the head! That issue is exactly what happening, and I already had that problem the last time I built the images (when I added the latest tag).

If you check the Dockerfile you can see that first I add the repositories I need to install the packages, then after installing I reset the repositories file by adding tags to the repositories (@edge-main, etc). I did this exactly due to that bug, but I didn't know that with 0 packages installed from those repositories it would throw an error.

I guess the only way now is to comment out the @edge-main, @edge-community and @edge-testing repositories, and let people deal with that problem (by, e.g. using a strategy similar to mine).

I'll keep an eye on the issue that you linked (thanks for that), and wait for a fix (it has been 28days since it was posted 😞 ).

jfloff commented 7 years ago

New latest-slimimage without the edge repositories is built already. Could you check if you still see the same problem?

Thanks in advance!

allan-simon commented 7 years ago

yes it works , awesome, thanks :)

jfloff commented 7 years ago

Thanks for the feedback!