-
Notifications
You must be signed in to change notification settings - Fork 2
/
dockerfile.app
30 lines (22 loc) · 1013 Bytes
/
dockerfile.app
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
29
30
FROM ruby:3.3.0
# Updating Pandoc version may result in a PDF build failure
ENV PANDOC_VERSION="2.16.1"
RUN wget --output-document="/pandoc-${PANDOC_VERSION}-linux-amd64.tar.gz" "https://github.com/jgm/pandoc/releases/download/${PANDOC_VERSION}/pandoc-${PANDOC_VERSION}-linux-amd64.tar.gz" && \
tar xf "pandoc-${PANDOC_VERSION}-linux-amd64.tar.gz" && \
ln -s "/pandoc-${PANDOC_VERSION}/bin/pandoc" "/usr/local/bin"
RUN apt update -y && apt install -y \
librsvg2-bin=2.54.7+dfsg-1~deb12u1 \
texlive-bibtex-extra=2022.20230122-4 \
texlive-latex-base=2022.20230122-3 \
texlive-latex-extra=2022.20230122-4
COPY . /app/
WORKDIR /app
RUN bundle install
EXPOSE 9292
WORKDIR /
# Change the date env value to re-download the updated gen-pdf script
ENV UPDATE_DATE="20240226-01"
RUN git clone "https://github.com/biohackrxiv/bhxiv-gen-pdf" --depth 1 && chmod +x /bhxiv-gen-pdf/bin/gen-pdf
ENV PATH $PATH:/bhxiv-gen-pdf/bin
WORKDIR /app
CMD ["bundle", "exec", "puma", "-C", "config/puma.rb"]