Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save richardsonlima/19c0b33cbf8962e85cdc8770e61cc534 to your computer and use it in GitHub Desktop.
Save richardsonlima/19c0b33cbf8962e85cdc8770e61cc534 to your computer and use it in GitHub Desktop.
FROM gliderlabs/alpine:latest
MAINTAINER info@megam.io
RUN apk update && apk --update add ruby \
ruby-io-console ca-certificates libssl1.0 openssl libstdc++ \
libxml2-dev libffi-dev
ADD Gemfile /app/
ADD Gemfile.lock /app/
RUN apk --update add --virtual build-dependencies ruby-dev build-base openssl-dev && \
gem install bundler --no-ri --no-rdoc && \
cd /app ; bundle install --without development test && \
apk del build-dependencies
ADD . /app
RUN chown -R nobody:nogroup /app
USER nobody
ENV RAILS_ENV development
EXPOSE 3000
WORKDIR /app
# Precompile Rails assets
# RUN bundle exec rake assets:precompile RAILS_ENV=production
CMD ["bundle", "exec", "passenger", "-p", "3000", "--max-pool-size"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment