webdav-aliyundriver/Dockerfile

12 lines
366 B
Docker
Raw Normal View History

2021-07-24 12:08:13 +08:00
FROM maven:3-jdk-8-alpine AS maven
2021-01-16 11:02:20 +08:00
USER root
COPY ./ /tmp/code
2021-01-16 11:09:07 +08:00
RUN cd /tmp/code && mvn clean package -Dmaven.test.skip=true -Dmaven.javadoc.skip=true
2021-01-16 11:02:20 +08:00
2021-07-24 12:08:13 +08:00
FROM openjdk:8-jdk-alpine
2021-05-23 09:32:29 +08:00
COPY --from=maven /tmp/code/target/*.jar /webdav.jar
2021-01-16 11:02:20 +08:00
EXPOSE 8080
2021-07-19 22:16:28 +08:00
ENV JAVA_OPTS="-Xmx1g"
2021-07-19 22:31:32 +08:00
ENTRYPOINT ["sh", "-c", "java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -jar /webdav.jar"]