-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
28 lines (21 loc) · 745 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
# plantuml image
FROM ubuntu AS plantuml
RUN apt-get update -y
RUN apt-get install -y wget default-jre default-jdk graphviz
RUN wget https://github.com/plantuml/plantuml/releases/download/v1.2022.13/plantuml-1.2022.13.jar -O plantuml.jar
RUN echo "#!/bin/bash" > plantuml ; echo "java -jar $PWD/plantuml.jar \"\$1\" \"\$2\"" >> plantuml
RUN mv plantuml /usr/bin/plantuml
RUN chmod +x /usr/bin/plantuml
# main image
FROM rust:slim-buster
RUN apt-get update && \
apt-get install --no-install-recommends -y \
libssl-dev pkg-config
RUN cargo install mdbook
RUN cargo install mdbook-plantuml
COPY --from=plantuml /usr/bin/plantuml /usr/bin/plantuml
EXPOSE 3000
WORKDIR /usr/src/app
# Copy project files
COPY . .
ENTRYPOINT ["mdbook"]