-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
43 lines (27 loc) · 1.22 KB
/
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
37
38
39
40
41
42
43
#asciidoctor/docker-asciidoctor
FROM asciidoctor/docker-asciidoctor AS base
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
# Minimal image with asciidoctor
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
FROM base AS main-minimal
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
# Haskell build for: erd
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
FROM base AS build-haskell
ARG FONTLANG
RUN addgroup -g 1000 -S demo && \
adduser -u 1000 -S demo -G demo --shell /bin/bash
USER demo
RUN cd /tmp && wget https://github.com/life888888/asciidoctor-pdf-cjk-ext/raw/main/install-zip-to-downloaded-resources-dir.sh && chmod u+x install-zip-to-downloaded-resources-dir.sh && /bin/bash ./install-zip-to-downloaded-resources-dir.sh $FONTLANG
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
# Final image
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
FROM main-minimal AS main
RUN addgroup -g 1000 -S demo && \
adduser -u 1000 -S demo -G demo --shell /bin/bash
COPY --from=build-haskell /home/demo/downloaded-resources /home/demo/downloaded-resources
RUN chown -R demo:demo /home/demo/downloaded-resources
USER demo
WORKDIR /documents
VOLUME /documents
CMD ["/bin/bash"]