-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
34 lines (23 loc) · 913 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
FROM ubuntu:20.04
RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install curl gnupg -y
# Download and import GPG keys required for RVM
RUN gpg --keyserver hkp://keyserver.ubuntu.com --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB || \
(curl -sSL https://rvm.io/mpapis.asc | gpg --import - && \
curl -sSL https://rvm.io/pkuczynski.asc | gpg --import -)
# Download RVM installer script
RUN curl -sSL https://get.rvm.io -o rvm-installer
# Install RVM
RUN bash rvm-installer
# Source RVM scripts
RUN echo 'source /etc/profile.d/rvm.sh' >> /etc/bash.bashrc
# Reload shell for RVM
SHELL ["/bin/bash", "-l", "-c"]
RUN rvm get stable --autolibs=enable
RUN usermod -a -G rvm root
RUN rvm --version
RUN for version in 3.0.1 3.1.0 3.2.0 3.3.0 3.4.0 3.4.2; do \
rvm install ruby-"$version"; \
done
RUN rvm --default use ruby-3.4.2