FROM ruby:2.3.3 MAINTAINER BioSistemika # additional dependecies RUN apt-get update -qq && \ apt-get install -y \ nodejs \ postgresql-client \ default-jre-headless \ sudo graphviz --no-install-recommends \ sudo libfile-mimeinfo-perl && \ rm -rf /var/lib/apt/lists/* # install gems COPY Gemfile* /tmp/ WORKDIR /tmp RUN bundle install # create app directory ENV APP_HOME /usr/src/app RUN mkdir $APP_HOME WORKDIR $APP_HOME COPY . . RUN rm -f $APP_HOME/config/application.yml RUN rm -f $APP_HOME/production.env ENV RAILS_ENV production ENV DATABASE_URL=postgresql://postgres@db/scinote_production RUN bash -c "PAPERCLIP_HASH_SECRET=$(openssl rand -base64 128 | tr -d '\n') SECRET_KEY_BASE=$(openssl rand -hex 64) rake assets:precompile" CMD rails s -b 0.0.0.0