Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker build fails because of incorrect version of Ruby #31

Closed
ElmoVanKielmo opened this issue Aug 31, 2017 · 5 comments
Closed

Docker build fails because of incorrect version of Ruby #31

ElmoVanKielmo opened this issue Aug 31, 2017 · 5 comments

Comments

@ElmoVanKielmo
Copy link

ElmoVanKielmo commented Aug 31, 2017

I tried to build today but with no success.

> docker build --tag redis-cluster:latest .redis-cluster-docker/
Sending build context to Docker daemon 3.072 kB
Step 1 : FROM redis:3.2
3.2: Pulling from library/redis
5233d9aed181: Pull complete 
ca1b33d3f114: Pull complete 
920cdc17d3c2: Pull complete 
039bc0a8c4af: Pull complete 
39d721bfb392: Pull complete 
853085e403eb: Pull complete 
Digest: sha256:848b4fd76a5dacb56988af810a6e86719e313cf4e1186f3d3050384686dbc120
Status: Downloaded newer image for redis:3.2
 ---> c6988031bc47
Step 2 : MAINTAINER Johan Andersson <Grokzen@gmail.com>
 ---> Running in 44fc25ade063
 ---> 9cf4c2e50647
Removing intermediate container 44fc25ade063
Step 3 : ENV HOME /root
 ---> Running in 6ca7f2b6fdac
 ---> 87c9b986d4fc
Removing intermediate container 6ca7f2b6fdac
Step 4 : ENV DEBIAN_FRONTEND noninteractive
 ---> Running in d09cfca6fe83
 ---> c7955ca3f33a
Removing intermediate container d09cfca6fe83
Step 5 : RUN apt-get update -qq &&     apt-get install --no-install-recommends -yqq       net-tools supervisor ruby rubygems locales gettext-base wget &&     apt-get clean -yqq
 ---> Running in c6c4da1654e5
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package libgdbm3:amd64.
(Reading database ... 7461 files and directories currently installed.)
Preparing to unpack .../libgdbm3_1.8.3-13.1_amd64.deb ...
Unpacking libgdbm3:amd64 (1.8.3-13.1) ...
Selecting previously unselected package libssl1.0.0:amd64.
Preparing to unpack .../libssl1.0.0_1.0.1t-1+deb8u6_amd64.deb ...
Unpacking libssl1.0.0:amd64 (1.0.1t-1+deb8u6) ...
Selecting previously unselected package libasprintf0c2:amd64.
Preparing to unpack .../libasprintf0c2_0.19.3-2_amd64.deb ...
Unpacking libasprintf0c2:amd64 (0.19.3-2) ...
Selecting previously unselected package libgmp10:amd64.
Preparing to unpack .../libgmp10_2%3a6.0.0+dfsg-6_amd64.deb ...
Unpacking libgmp10:amd64 (2:6.0.0+dfsg-6) ...
Selecting previously unselected package libnettle4:amd64.
Preparing to unpack .../libnettle4_2.7.1-5+deb8u2_amd64.deb ...
Unpacking libnettle4:amd64 (2.7.1-5+deb8u2) ...
Selecting previously unselected package libhogweed2:amd64.
Preparing to unpack .../libhogweed2_2.7.1-5+deb8u2_amd64.deb ...
Unpacking libhogweed2:amd64 (2.7.1-5+deb8u2) ...
Selecting previously unselected package libffi6:amd64.
Preparing to unpack .../libffi6_3.1-2+deb8u1_amd64.deb ...
Unpacking libffi6:amd64 (3.1-2+deb8u1) ...
Selecting previously unselected package libp11-kit0:amd64.
Preparing to unpack .../libp11-kit0_0.20.7-1_amd64.deb ...
Unpacking libp11-kit0:amd64 (0.20.7-1) ...
Selecting previously unselected package libtasn1-6:amd64.
Preparing to unpack .../libtasn1-6_4.2-3+deb8u3_amd64.deb ...
Unpacking libtasn1-6:amd64 (4.2-3+deb8u3) ...
Selecting previously unselected package libgnutls-deb0-28:amd64.
Preparing to unpack .../libgnutls-deb0-28_3.3.8-6+deb8u7_amd64.deb ...
Unpacking libgnutls-deb0-28:amd64 (3.3.8-6+deb8u7) ...
Selecting previously unselected package libidn11:amd64.
Preparing to unpack .../libidn11_1.29-1+deb8u2_amd64.deb ...
Unpacking libidn11:amd64 (1.29-1+deb8u2) ...
Selecting previously unselected package libsqlite3-0:amd64.
Preparing to unpack .../libsqlite3-0_3.8.7.1-1+deb8u2_amd64.deb ...
Unpacking libsqlite3-0:amd64 (3.8.7.1-1+deb8u2) ...
Selecting previously unselected package libpython2.7-minimal:amd64.
Preparing to unpack .../libpython2.7-minimal_2.7.9-2+deb8u1_amd64.deb ...
Unpacking libpython2.7-minimal:amd64 (2.7.9-2+deb8u1) ...
Selecting previously unselected package python2.7-minimal.
Preparing to unpack .../python2.7-minimal_2.7.9-2+deb8u1_amd64.deb ...
Unpacking python2.7-minimal (2.7.9-2+deb8u1) ...
Selecting previously unselected package python-minimal.
Preparing to unpack .../python-minimal_2.7.9-1_amd64.deb ...
Unpacking python-minimal (2.7.9-1) ...
Selecting previously unselected package mime-support.
Preparing to unpack .../mime-support_3.58_all.deb ...
Unpacking mime-support (3.58) ...
Selecting previously unselected package libexpat1:amd64.
Preparing to unpack .../libexpat1_2.1.0-6+deb8u4_amd64.deb ...
Unpacking libexpat1:amd64 (2.1.0-6+deb8u4) ...
Selecting previously unselected package libpython2.7-stdlib:amd64.
Preparing to unpack .../libpython2.7-stdlib_2.7.9-2+deb8u1_amd64.deb ...
Unpacking libpython2.7-stdlib:amd64 (2.7.9-2+deb8u1) ...
Selecting previously unselected package python2.7.
Preparing to unpack .../python2.7_2.7.9-2+deb8u1_amd64.deb ...
Unpacking python2.7 (2.7.9-2+deb8u1) ...
Selecting previously unselected package libpython-stdlib:amd64.
Preparing to unpack .../libpython-stdlib_2.7.9-1_amd64.deb ...
Unpacking libpython-stdlib:amd64 (2.7.9-1) ...
Setting up libpython2.7-minimal:amd64 (2.7.9-2+deb8u1) ...
Setting up python2.7-minimal (2.7.9-2+deb8u1) ...
Setting up python-minimal (2.7.9-1) ...
Selecting previously unselected package python.
(Reading database ... 8361 files and directories currently installed.)
Preparing to unpack .../python_2.7.9-1_amd64.deb ...
Unpacking python (2.7.9-1) ...
Selecting previously unselected package libicu52:amd64.
Preparing to unpack .../libicu52_52.1-8+deb8u5_amd64.deb ...
Unpacking libicu52:amd64 (52.1-8+deb8u5) ...
Selecting previously unselected package libyaml-0-2:amd64.
Preparing to unpack .../libyaml-0-2_0.1.6-3_amd64.deb ...
Unpacking libyaml-0-2:amd64 (0.1.6-3) ...
Selecting previously unselected package net-tools.
Preparing to unpack .../net-tools_1.60-26+b1_amd64.deb ...
Unpacking net-tools (1.60-26+b1) ...
Selecting previously unselected package libpsl0:amd64.
Preparing to unpack .../libpsl0_0.5.1-1_amd64.deb ...
Unpacking libpsl0:amd64 (0.5.1-1) ...
Selecting previously unselected package wget.
Preparing to unpack .../wget_1.16-1+deb8u2_amd64.deb ...
Unpacking wget (1.16-1+deb8u2) ...
Selecting previously unselected package gettext-base.
Preparing to unpack .../gettext-base_0.19.3-2_amd64.deb ...
Unpacking gettext-base (0.19.3-2) ...
Selecting previously unselected package locales.
Preparing to unpack .../locales_2.19-18+deb8u10_all.deb ...
Unpacking locales (2.19-18+deb8u10) ...
Selecting previously unselected package openssl.
Preparing to unpack .../openssl_1.0.1t-1+deb8u6_amd64.deb ...
Unpacking openssl (1.0.1t-1+deb8u6) ...
Selecting previously unselected package ca-certificates.
Preparing to unpack .../ca-certificates_20141019+deb8u3_all.deb ...
Unpacking ca-certificates (20141019+deb8u3) ...
Selecting previously unselected package python-pkg-resources.
Preparing to unpack .../python-pkg-resources_5.5.1-1_all.deb ...
Unpacking python-pkg-resources (5.5.1-1) ...
Selecting previously unselected package rubygems-integration.
Preparing to unpack .../rubygems-integration_1.8_all.deb ...
Unpacking rubygems-integration (1.8) ...
Selecting previously unselected package libruby2.1:amd64.
Preparing to unpack .../libruby2.1_2.1.5-2+deb8u3_amd64.deb ...
Unpacking libruby2.1:amd64 (2.1.5-2+deb8u3) ...
Selecting previously unselected package ruby2.1.
Preparing to unpack .../ruby2.1_2.1.5-2+deb8u3_amd64.deb ...
Unpacking ruby2.1 (2.1.5-2+deb8u3) ...
Selecting previously unselected package ruby.
Preparing to unpack .../ruby_1%3a2.1.5+deb8u2_all.deb ...
Unpacking ruby (1:2.1.5+deb8u2) ...
Selecting previously unselected package python-meld3.
Preparing to unpack .../python-meld3_1.0.0-1_amd64.deb ...
Unpacking python-meld3 (1.0.0-1) ...
Selecting previously unselected package supervisor.
Preparing to unpack .../supervisor_3.0r1-1+deb8u1_all.deb ...
Unpacking supervisor (3.0r1-1+deb8u1) ...
Processing triggers for systemd (215-17+deb8u7) ...
Setting up libgdbm3:amd64 (1.8.3-13.1) ...
Setting up libssl1.0.0:amd64 (1.0.1t-1+deb8u6) ...
Setting up libasprintf0c2:amd64 (0.19.3-2) ...
Setting up libgmp10:amd64 (2:6.0.0+dfsg-6) ...
Setting up libnettle4:amd64 (2.7.1-5+deb8u2) ...
Setting up libhogweed2:amd64 (2.7.1-5+deb8u2) ...
Setting up libffi6:amd64 (3.1-2+deb8u1) ...
Setting up libp11-kit0:amd64 (0.20.7-1) ...
Setting up libtasn1-6:amd64 (4.2-3+deb8u3) ...
Setting up libgnutls-deb0-28:amd64 (3.3.8-6+deb8u7) ...
Setting up libidn11:amd64 (1.29-1+deb8u2) ...
Setting up libsqlite3-0:amd64 (3.8.7.1-1+deb8u2) ...
Setting up mime-support (3.58) ...
Setting up libexpat1:amd64 (2.1.0-6+deb8u4) ...
Setting up libpython2.7-stdlib:amd64 (2.7.9-2+deb8u1) ...
Setting up python2.7 (2.7.9-2+deb8u1) ...
Setting up libpython-stdlib:amd64 (2.7.9-1) ...
Setting up python (2.7.9-1) ...
Setting up libicu52:amd64 (52.1-8+deb8u5) ...
Setting up libyaml-0-2:amd64 (0.1.6-3) ...
Setting up net-tools (1.60-26+b1) ...
Setting up libpsl0:amd64 (0.5.1-1) ...
Setting up wget (1.16-1+deb8u2) ...
Setting up gettext-base (0.19.3-2) ...
Setting up locales (2.19-18+deb8u10) ...
Generating locales (this might take a while)...
Generation complete.
Setting up openssl (1.0.1t-1+deb8u6) ...
Setting up ca-certificates (20141019+deb8u3) ...
Updating certificates in /etc/ssl/certs... 174 added, 0 removed; done.
Setting up python-pkg-resources (5.5.1-1) ...
Setting up rubygems-integration (1.8) ...
Setting up libruby2.1:amd64 (2.1.5-2+deb8u3) ...
Setting up ruby2.1 (2.1.5-2+deb8u3) ...
Setting up ruby (1:2.1.5+deb8u2) ...
Setting up python-meld3 (1.0.0-1) ...
Setting up supervisor (3.0r1-1+deb8u1) ...
invoke-rc.d: policy-rc.d denied execution of start.
Processing triggers for libc-bin (2.19-18+deb8u10) ...
Processing triggers for ca-certificates (20141019+deb8u3) ...
Updating certificates in /etc/ssl/certs... 0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d....done.
Processing triggers for systemd (215-17+deb8u7) ...
 ---> 2f930113e334
Removing intermediate container c6c4da1654e5
Step 6 : RUN locale-gen en_US.UTF-8
 ---> Running in eeed1bfbf66f
Generating locales (this might take a while)...
Generation complete.
 ---> 67765fd9cca2
Removing intermediate container eeed1bfbf66f
Step 7 : ENV LANG en_US.UTF-8
 ---> Running in 5f56b0788e0e
 ---> 0f4aecf9391d
Removing intermediate container 5f56b0788e0e
Step 8 : ENV LC_ALL en_US.UTF-8
 ---> Running in d88ec2f9983f
 ---> 64e43aeaf778
Removing intermediate container d88ec2f9983f
Step 9 : RUN gem install redis
 ---> Running in 04fef0cb63cd
ERROR:  Error installing redis:
	redis requires Ruby version >= 2.2.2.
The command '/bin/sh -c gem install redis' returned a non-zero code: 1
@mostevercxz
Copy link

I got the same error msg when running 'docker build redis-cluster-docker'.

root@localhost:~# cat /etc/issue
Ubuntu 16.04.2 LTS \n \l

@ghost
Copy link

ghost commented Sep 4, 2017

same issue here ... what can i do when see that's error ?

andrei1489 added a commit to andrei1489/docker-redis-cluster that referenced this issue Sep 4, 2017
Version 4 of redis gem required a higher version of redis ( Issue Grokzen#31)
@ghost
Copy link

ghost commented Sep 5, 2017

what a solution ? anyone ? installing from ubuntu 16.04.02

@andrei1489
Copy link

andrei1489 commented Sep 5, 2017

@skyThink You need to lock the version of the redis gem. I did it by adding -v 3.3.3 to the gem install redis command. Its the last version before redis version 4. I don't know if it's the best solution, but i needed it fixed quickly.

@Grokzen
Copy link
Owner

Grokzen commented Dec 3, 2017

I have committed a fix to bind the ruby gem to version 3.3.3 as @andrei1489 suggested in the master branch. If you rebuild the image it should work again. Closing this one as resolved.

@Grokzen Grokzen closed this as completed Dec 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants