1
0
mirror of https://github.com/octoleo/plantuml-server.git synced 2024-11-14 16:34:08 +00:00
plantuml-server/Dockerfile.jetty
Peter Dave Hello 04af2a25d2 Remove apt-get clean in Dockerfile.{jetty,tomcat}
Also manually cleaned up `/var/lib/apt/lists` in original commits but
got conflict with #97, then removed.

Ref:
https://docs.docker.com/develop/develop-images/dockerfile_best-practices/

> In addition, when you clean up the apt cache by removing
> /var/lib/apt/lists it reduces the image size, since the apt cache is not
> stored in a layer.

> Official Debian and Ubuntu images automatically run apt-get clean,
> so explicit invocation is not required.
2021-04-23 22:25:45 +02:00

26 lines
584 B
Docker

FROM maven:3-jdk-11 AS builderjetty
COPY pom.xml /app/
COPY src /app/src/
WORKDIR /app
RUN mvn --batch-mode --define java.net.useSystemProxies=true package
########################################################################################
FROM jetty:9.4-jre11
MAINTAINER D.Ducatel
USER root
RUN apt-get update && \
apt-get install -y --no-install-recommends graphviz fonts-noto-cjk && \
rm -rf /var/lib/apt/lists/*
USER jetty
ENV GRAPHVIZ_DOT=/usr/bin/dot
ARG BASE_URL=ROOT
COPY --from=builderjetty /app/target/plantuml.war /var/lib/jetty/webapps/$BASE_URL.war