Browse Source

nacos持久化

master
wangjx 3 years ago
parent
commit
b17da76325
1 changed files with 13 additions and 2 deletions
  1. +13
    -2
      Dockerfile

+ 13
- 2
Dockerfile View File

@@ -1,12 +1,23 @@
FROM java:8 FROM java:8
MAINTAINER king <1609724385@qq.com> MAINTAINER king <1609724385@qq.com>
VOLUME /tmp VOLUME /tmp
COPY sentinel-dashboard/target/sentinel-dashboard.jar app.jar

COPY sentinel-core/target/sentinel-core.jar core.jar
COPY --from=hengyunabc/arthas:latest /opt/arthas /opt/arthas COPY --from=hengyunabc/arthas:latest /opt/arthas /opt/arthas
ENV TimeZone=Asia/Shanghai ENV TimeZone=Asia/Shanghai
ENV active=dev
ENV active=test
ENV JAVA_OPTS="-Xmx512M -Xms512M" ENV JAVA_OPTS="-Xmx512M -Xms512M"
RUN ln -snf /usr/share/zoneinfo/$TimeZone /etc/localtime && echo $TimeZone > /etc/timezone RUN ln -snf /usr/share/zoneinfo/$TimeZone /etc/localtime && echo $TimeZone > /etc/timezone
#EXPOSE 8098 #EXPOSE 8098

COPY sentinel-dashboard/target/sentinel-dashboard.jar app.jar
COPY --from=hengyunabc/arthas:latest /opt/arthas /opt/arthas
#ENV TimeZone=Asia/Shanghai
#ENV active=test
#ENV JAVA_OPTS="-Xmx512M -Xms512M"
#RUN ln -snf /usr/share/zoneinfo/$TimeZone /etc/localtime && echo $TimeZone > /etc/timezone
#EXPOSE 8098
ENTRYPOINT java $JAVA_OPTS -jar /core.jar --spring.profiles.active=$active

ENTRYPOINT java $JAVA_OPTS -Dserver.port=7777 -Dcsp.sentinel.dashboard.server=$IP:7777 -Dproject ENTRYPOINT java $JAVA_OPTS -Dserver.port=7777 -Dcsp.sentinel.dashboard.server=$IP:7777 -Dproject
.name=sentinel-dashboard -Dsentinel.dashboard.auth.username=telpo -Dsentinel.dashboard.auth.password=telpo#1234 -jar /app.jar --spring.profiles.active=$active .name=sentinel-dashboard -Dsentinel.dashboard.auth.username=telpo -Dsentinel.dashboard.auth.password=telpo#1234 -jar /app.jar --spring.profiles.active=$active

Loading…
Cancel
Save