mirror of
https://github.com/CodeforLeipzig/stadtratmonitor.git
synced 2024-12-22 23:53:15 +01:00
35 lines
1.1 KiB
Docker
Executable file
35 lines
1.1 KiB
Docker
Executable file
FROM ruby:2.5.7
|
|
RUN gem install bundler
|
|
|
|
# Add google package repository for google chrome
|
|
RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
|
|
&& echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list
|
|
|
|
RUN apt-get update && \
|
|
apt-get install -y build-essential zlib1g-dev libsqlite3-dev nodejs npm \
|
|
libxml2-dev libxslt1-dev pkg-config google-chrome-stable
|
|
|
|
|
|
ENV DOCKERIZE_VERSION v0.6.1
|
|
RUN curl -sSLO https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz \
|
|
&& tar -C /usr/local/bin -xzvf dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz \
|
|
&& rm dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz
|
|
|
|
RUN mkdir -p /app
|
|
|
|
WORKDIR /tmp
|
|
|
|
COPY Gemfile Gemfile
|
|
COPY Gemfile.lock Gemfile.lock
|
|
RUN bundle config build.nokogiri --use-system-libraries
|
|
RUN bundle install
|
|
|
|
ADD . /app
|
|
WORKDIR /app
|
|
|
|
COPY ./docker-entrypoint.sh /
|
|
RUN chmod +x docker-entrypoint.sh
|
|
|
|
EXPOSE 3000
|
|
ENTRYPOINT ["/docker-entrypoint.sh"]
|
|
CMD ["rails", "server", "-b", "0.0.0.0"]
|