Closed niko closed 11 months ago
Strange enough install in the docker ruby:2.5-alpine container just works:
$ docker run -it ruby:2.5-alpine gem install libv8
Fetching: libv8-6.3.292.48.1-x86_64-linux.gem (100%)
Successfully installed libv8-6.3.292.48.1-x86_64-linux
1 gem installed
Notable similarities: It's the exact same version.
Notable difference: It's not building native extensions. And that's where my local install fails.
gem
version is 2.7.7 in docker and 2.7.6 native.
There seems to be lack of upstream support of the SDK with Alpine at this point:
Reference issues:
Star those issues to help get them resolved or even better -- suggest patches.
Any idea why this just works within a docker container?
Hey, it does not.
If you take a closer look, gem
downloads the Linux binary version Fetching: libv8-6.3.292.48.1-*x86_64-linux*.gem (100%)
This has been linked against glibc, which makes it unusable on Alpine afaik. :(
Huh... Actually it might work -- the Dockerfile you're using downloads and compiles Ruby from source which I think is linked against glibc... https://github.com/docker-library/ruby/blob/699a04311386ecc98ca242fc9bdee17fb4008863/2.5/alpine3.7/Dockerfile
The Ruby in Alpine's repos is not and in fact is patched to not use binary versions of gems because of the reason I outlined in the comment above.
Oh. Right. That makes sense.
Made a comment here regarding musl support and a possible partially upstream solution: https://github.com/rubyjs/libv8/issues/270#issuecomment-573063347
Closing as this issue is completely sidestepped in libv8-node, and has musl builds.
I'm getting an error when trying to install
libv8
. I'm using Ruby 2.5.0 on Alpine Linux. It seems to be a problem with downloading the sources.