From 6169e7cfabc7d495bdafb98f96df87b7423e80e6 Mon Sep 17 00:00:00 2001 From: pierreozoux <pierre@ozoux.net> Date: Thu, 9 Jun 2016 09:09:51 +0100 Subject: [PATCH] One layer for env --- Dockerfile | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index aee65fe..192653e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,12 @@ FROM rails:4.1 WORKDIR /usr/src/app -ENV DISCOURSE_VERSION 1.4.7 +ENV DISCOURSE_VERSION=1.4.7 \ + RAILS_ENV=production \ + RUBY_GC_MALLOC_LIMIT=90000000 \ + DISCOURSE_DB_HOST=postgres \ + DISCOURSE_REDIS_HOST=redis \ + DISCOURSE_SERVE_STATIC_ASSETS=true RUN apt-get update && apt-get install -y --no-install-recommends imagemagick libxml2 \ && rm -rf /var/lib/apt/lists/* @@ -12,11 +17,5 @@ RUN curl -L https://github.com/discourse/discourse/archive/v${DISCOURSE_VERSION} && bundle config build.nokogiri --use-system-libraries \ && bundle install --deployment --without test --without development -ENV RAILS_ENV production -ENV RUBY_GC_MALLOC_LIMIT 90000000 -ENV DISCOURSE_DB_HOST postgres -ENV DISCOURSE_REDIS_HOST redis -ENV DISCOURSE_SERVE_STATIC_ASSETS true - EXPOSE 3000 CMD ["rails", "server"] -- GitLab