Created
June 23, 2014 07:41
-
-
Save ippa/0b7ea8692f1ae94e5722 to your computer and use it in GitHub Desktop.
rvm as normal user (non-root) Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:trusty | |
MAINTAINER ippa | |
ENV DEBIAN_FRONTEND noninteractive | |
RUN unset HISTFILE | |
# required by RVM | |
RUN apt-get -y update | |
RUN apt-get -y install patch gawk g++ gcc make libc6-dev patch libreadline6-dev zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 autoconf libgdbm-dev libncurses5-dev automake libtool bison pkg-config libffi-dev | |
RUN apt-get -y install curl | |
# create user 'ruby' and install all rvm-stuff as that user | |
RUN useradd --create-home --shell /bin/bash --user-group ruby | |
RUN su ruby -c "curl -sSL https://get.rvm.io | bash -s stable --ruby" | |
RUN su -l ruby -s /bin/bash --login && \ | |
/bin/bash -l /home/ruby/.rvm/bin/rvm reload && \ | |
/bin/bash -l /home/ruby/.rvm/bin/rvm use --default 2.1.1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment