-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
28 lines (21 loc) · 944 Bytes
/
Dockerfile
File metadata and controls
28 lines (21 loc) · 944 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
FROM ruby:3.2-slim
# update the repository sources list
# and install dependencies
RUN apt-get update \
&& apt-get install -y nodejs curl git build-essential libpq-dev libmagic-dev libvips-dev libyaml-dev \
&& apt-get -y autoclean
RUN curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > /usr/local/bin/cc-test-reporter
RUN chmod +x /usr/local/bin/cc-test-reporter
RUN useradd -ms /bin/bash cerberus
USER cerberus
RUN mkdir -p /home/cerberus/storage
RUN mkdir -p /home/cerberus/images
COPY --chown=cerberus:cerberus Gemfile* /tmp/
WORKDIR /tmp
RUN git config --global url."https://github.com/".insteadOf 'git@github.com:'
RUN bundle install -j8
RUN mkdir -p /home/cerberus/web
WORKDIR /home/cerberus/web
RUN echo "IRB.conf[:USE_AUTOCOMPLETE] = false" > /home/cerberus/.irbrc
COPY --chown=cerberus:cerberus . /home/cerberus/web
RUN git config --global --add safe.directory /home/cerberus/web