FROM maven:3-jdk-8 AS builder RUN apt-get update && apt-get install -y --no-install-recommends graphviz fonts-wqy-zenhei && rm -rf /var/lib/apt/lists/* COPY pom.xml /app/ COPY src /app/src/ ENV MAVEN_CONFIG=/app/.m2 WORKDIR /app RUN mvn package ######################################################################################## FROM tomcat:9 MAINTAINER D.Ducatel RUN apt-get update && \ apt-get install -y --no-install-recommends graphviz fonts-wqy-zenhei && \ rm -rf /var/lib/apt/lists/* RUN rm -rf /usr/local/tomcat/webapps/ROOT COPY --from=builder /app/target/plantuml.war /usr/local/tomcat/webapps/ROOT.war