添加正式环境docker构建文件

This commit is contained in:
walker-sheng 2020-11-26 19:42:35 +08:00
parent a2ca5c5981
commit e3304dbe24
1 changed files with 16 additions and 0 deletions

16
Dockerfile-prd Normal file
View File

@ -0,0 +1,16 @@
from centos:7
ADD jre-11 jre-11
ADD target/rtss-0.0.1-SNAPSHOT.jar app.jar
ENV JAVA_HOME=/jre-11
ENV PATH=$JAVA_HOME/bin:$PATH
ENV LANG=C.UTF-8
EXPOSE 9000 19000/tcp
ENV TZ=Asia/Shanghai
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
CMD java -jar -Dfile.encoding=UTF-8 -Dspring.profiles.active=prd /app.jar