summaryrefslogtreecommitdiff
path: root/Dockerfile
blob: 8aba27c1e7fff016d0d377774bf72ece89ed7e2f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
FROM alpine:latest
MAINTAINER mo@mokhan.ca

RUN apk update && \
  apk upgrade && \
  apk add openjdk8 maven ruby nodejs yarn chromium nss freetype freetype-dev harfbuzz ca-certificates ttf-freefont && \
  gem install bundler:'~> 2.0' --no-document && \
  mkdir -p /code

WORKDIR /code
COPY . /code
RUN bundle install --jobs $(nproc) && yarn install && mvn install
RUN sed -i 's/{ headless: true }/{ headless: true, executablePath: "\/usr\/bin\/chromium-browser", args: ["--no-sandbox", "--disable-setuid-sandbox"] }/g' node_modules/mdpdf/src/index.js
CMD ["bundle", "exec", "rake", "run"]