-
Notifications
You must be signed in to change notification settings - Fork 25
/
Dockerfile
36 lines (23 loc) · 716 Bytes
/
Dockerfile
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
31
32
33
34
35
36
FROM golang:buster AS rmapi
ENV GOPATH /go
ENV PATH ${GOPATH}/bin:/usr/local/go/bin:$PATH
ENV RMAPIREPO github.com/juruen/rmapi
RUN git clone https://${RMAPIREPO} && cd rmapi && go install
FROM python:3.7-slim-buster
# rmapi
COPY --from=rmapi /go/bin/rmapi /usr/bin/rmapi
# needed to install openjdk-11-jre-headless
RUN mkdir -p /usr/share/man/man1
# imagemagick, pdftk, ghostscript, pdfcrop, weasyprint
RUN apt-get update \
&& apt-get install --no-install-recommends -y \
libmagickwand-dev \
pdftk \
ghostscript \
poppler-utils
RUN pip install --no-cache-dir paper2remarkable
RUN useradd -u 1000 -m -U user
USER user
ENV USER user
WORKDIR /home/user
ENTRYPOINT ["p2r"]