java项目Dockerfile配置
作者:互联网
FROM openjdk:11-jre
RUN cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
&& echo "Asia/Shanghai" > /etc/timezone
ARG JAR_FILE
COPY ${JAR_FILE} /app.jar
ENTRYPOINT ["java", "-Xmx512m", "-Djava.security.egd=file:/dev/./urandom", "-Ddruid.mysql.usePingMethod=false", "-jar", "/app.jar"]
CMD ["--spring.profiles.active=docker"]
标签:配置,java,app,Shanghai,jar,Asia,FILE,Dockerfile 来源: https://blog.csdn.net/zhangyizhanghao/article/details/122091063