# 基础镜像
FROM  openjdk:8-jre
# author
MAINTAINER ruoyi
# 设置时区 容器内是UTC时区 改为按照宿主机时区运行
RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone
# 挂载目录
VOLUME /home/ruoyi
# 创建目录
RUN mkdir -p /home/ruoyi
# 指定路径
WORKDIR /home/ruoyi
# 复制jar文件到路径
COPY ./jar/ruoyi-modules-job.jar /home/ruoyi/ruoyi-modules-job.jar
# 启动系统服务
ENTRYPOINT ["java","-jar","ruoyi-modules-job.jar"]