many important fixes

This commit is contained in:
2020-02-29 11:43:00 -05:00
parent 2149345d3d
commit 73c207c324
28 changed files with 1463 additions and 242 deletions
+19 -8
View File
@@ -1,7 +1,15 @@
FROM ruby:2.3.0-slim
FROM ruby:2.7-slim
#NOTE: this file must be built from the parent (../) directory
# look at the
# rebuild-docker.sh
# script as kind of manual on how the drb_counter cointainer is managed and used
# throw errors if Gemfile has been modified since Gemfile.lock
RUN bundle config --global frozen 1
#RUN bundle config --global frozen 1
RUN apt update
RUN apt install -y curl
RUN gem install bundler:1.17.3
RUN mkdir -p /usr/src/app
@@ -15,14 +23,17 @@ WORKDIR /usr/src/app
# Specific
#RUN apt-get update && apt-get install -y dos2unix --no-install-recommends && rm -rf /var/lib/apt/lists/*
COPY Gemfile /usr/src/app/
COPY Gemfile.lock /usr/src/app/
COPY drb_counter/Gemfile /usr/src/app/
#COPY drb_counter/Gemfile.lock /usr/src/app/
#COPY vendor/cache /usr/src/app/vendor/cache
#RUN bundle install --local
RUN rm -rf /usr/src/app/.bundle
#RUN bundle install
#RUN rm -rf /usr/src/app/.bundle
RUN bundle install
COPY . /usr/src/app
# COPY THE WHOLE DIRECTORY LATER THAN GEMFILE TO AVOID bundle install step on code change
COPY drb_counter /usr/src/app
RUN mkdir -p config
COPY config/couchdb.yml /usr/src/app/config/couchdb.yml
EXPOSE 9022
ENTRYPOINT ["ruby", "drb_counter.rb"]
CMD ["ruby", "drb_counter.rb"]