Retrospring/.docker/ruby/Dockerfile

26 lines
602 B
Docker
Raw Normal View History

2020-04-19 05:59:50 -07:00
FROM ruby:2.7
2020-04-18 16:17:37 -07:00
2020-05-09 01:16:30 -07:00
RUN curl -sL https://deb.nodesource.com/setup_12.x | bash -
2020-04-18 16:17:37 -07:00
RUN apt-get update -qq \
&& apt-get install -y --no-install-recommends build-essential \
2020-05-09 01:16:30 -07:00
libpq-dev postgresql-client \
libxml2-dev libxslt1-dev \
libmagickwand-dev imagemagick \
nodejs \
&& rm -rf /var/lib/apt/lists/*
2020-04-18 16:17:37 -07:00
2020-05-09 01:16:30 -07:00
RUN mkdir /app
WORKDIR /app
2020-04-18 16:17:37 -07:00
2020-05-09 01:16:30 -07:00
ADD Gemfile* /app/
RUN bundle install --jobs=$(nproc)
2020-10-20 02:47:00 -07:00
RUN gem install ruby-debug-ide
2020-05-09 01:16:30 -07:00
COPY . /app
2020-04-18 16:17:37 -07:00
2020-05-09 01:16:30 -07:00
COPY .docker/entrypoint.sh /usr/bin/
RUN chmod +x /usr/bin/entrypoint.sh
ENTRYPOINT ["entrypoint.sh"]
2020-04-19 05:59:50 -07:00
EXPOSE 3000
2020-05-09 01:16:30 -07:00
CMD ["rails", "server", "-b", "0.0.0.0"]