Created
May 15, 2018 03:43
-
-
Save y13i/c695ce19d502d3815469848ada07a8cb to your computer and use it in GitHub Desktop.
Ruby on Rails on Docker & Alpine Linux
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 ruby:2.5-alpine | |
RUN mkdir /app | |
WORKDIR /app | |
RUN \ | |
set -x \ | |
&& apk upgrade --no-cache \ | |
&& apk add --no-cache --virtual \ | |
build-dependencies \ | |
&& apk add --no-cache \ | |
build-base \ | |
tzdata \ | |
postgresql-dev \ | |
libxml2-dev \ | |
libxslt-dev | |
COPY Gemfile . | |
COPY Gemfile.lock . | |
RUN \ | |
set -x \ | |
&& gem install rake \ | |
&& bundle config build.nokogiri --use-system-libraries \ | |
&& bundle install \ | |
&& apk del build-dependencies | |
COPY . . | |
RUN rm -rf log tmp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment