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

jmalloc ? #201

Closed
grosser opened this issue Mar 22, 2018 · 2 comments
Closed

jmalloc ? #201

grosser opened this issue Mar 22, 2018 · 2 comments

Comments

@grosser
Copy link

grosser commented Mar 22, 2018

would you accept a PR to add ruby-2.5.0-alpine-jmalloc (or whatever the name would be) ?

got it working with this simplistic Dockerfile, but would try to edit the existing one in the repo to add a flag to install jmalloc optionally

FROM alpine

WORKDIR /

# 1 line to remove unnecessary build tools and reduce image size
RUN apk add --update --no-cache --virtual ruby-dependencies \
    linux-headers build-base bash libc-dev readline-dev jemalloc-dev libressl-dev && \

    wget -O ruby-install-0.6.1.tar.gz https://github.com/postmodern/ruby-install/archive/v0.6.1.tar.gz && \

    tar -xzvf ruby-install-0.6.1.tar.gz && \
    cd ruby-install-0.6.1/ && \
    make install && \

    ruby-install --system ruby 2.5.0 && \

    make uninstall && \
    cd / && rm -rf ruby-install-0.6.1 && \

    apk del ruby-dependencies

RUN echo "gem: --no-document" > ~/.gemrc

RUN gem install bundler
@tianon
Copy link
Member

tianon commented Mar 23, 2018

Duplicate of #182 😉

@tianon tianon closed this as completed Mar 23, 2018
@grosser
Copy link
Author

grosser commented Mar 23, 2018

FYI dug further and this example does not work ...

docker run + ruby -r rbconfig -e RbConfig::CONFIG\[\'LIBS\'\].include\?\(\'jemalloc\'\)\ \?\ puts\(\'Ruby\ is\ compiled\ with\ jemalloc\'\)\ :\ warn\(\'JEMALLOC\ IS\ MISSING\ FROM\ RUBY\'\)
JEMALLOC IS MISSING FROM RUBY

... tried a bunch of config options without success :/

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

2 participants