Skip to content

Commit 72ae3ff

Browse files
committed
Add "2.0" as a supported version of Ruby (since upstream officially supports it with security updates)
1 parent 2c035ec commit 72ae3ff

File tree

2 files changed

+37
-0
lines changed

2 files changed

+37
-0
lines changed

2.0/Dockerfile

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
FROM buildpack-deps:jessie
2+
3+
ENV RUBY_MAJOR 2.0
4+
ENV RUBY_VERSION 2.0.0-p481
5+
6+
# some of ruby's build scripts are written in ruby
7+
# we purge this later to make sure our final image uses what we just built
8+
RUN apt-get update \
9+
&& apt-get install -y bison curl ruby procps \
10+
&& rm -rf /var/lib/apt/lists/* \
11+
&& mkdir -p /usr/src/ruby \
12+
&& curl -SL "http://cache.ruby-lang.org/pub/ruby/$RUBY_MAJOR/ruby-$RUBY_VERSION.tar.bz2" \
13+
| tar -xjC /usr/src/ruby --strip-components=1 \
14+
&& cd /usr/src/ruby \
15+
&& autoconf \
16+
&& ./configure --disable-install-doc \
17+
&& make -j"$(nproc)" \
18+
&& apt-get purge -y --auto-remove bison ruby procps \
19+
&& make install \
20+
&& rm -r /usr/src/ruby
21+
22+
# skip installing gem documentation
23+
RUN echo 'gem: --no-rdoc --no-ri' >> /.gemrc
24+
25+
RUN gem install bundler
26+
27+
CMD [ "irb" ]

2.0/onbuild/Dockerfile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
FROM ruby:2.0.0-p481
2+
3+
RUN mkdir -p /usr/src/app
4+
WORKDIR /usr/src/app
5+
6+
ONBUILD ADD Gemfile /usr/src/app/
7+
ONBUILD ADD Gemfile.lock /usr/src/app/
8+
ONBUILD RUN bundle install --system
9+
10+
ONBUILD ADD . /usr/src/app

0 commit comments

Comments
 (0)