Commit 5648bd9c authored by liaozan's avatar liaozan 🏀

Update the directory of gc log

parent 2b91c42a
......@@ -10,12 +10,12 @@ COPY --from=builder app/spring-boot-loader/ ./
COPY --from=builder app/snapshot-dependencies/ ./
COPY --from=builder app/application/ ./
RUN mkdir -p /data/logs
RUN mkdir -p /data/logs/gc
ENV EXT_JVM_OPTS="${JAVA_OPTS}"
ENV JVM_OPTS="-XX:MaxRAMPercentage=80 -XX:+AlwaysPreTouch\
-XX:+UseG1GC -Xlog:gc*=debug:/data/logs/gc-%t.log:time,uptime\
ENV JVM_OPTS="-XX:MaxRAMPercentage=75 -XX:MetaspaceSize=256m -XX:MaxMetaspaceSize=256m\
-XX:+UseG1GC -XX:G1HeapRegionSize=2m -Xlog:gc*:/data/logs/gc/gc-%t.log:time,uptime\
-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/data/heapdump.hprof\
-XX:-OmitStackTraceInFastThrow -XX:+PrintCommandLineFlags $EXT_JVM_OPTS"
......
......@@ -28,7 +28,7 @@ spec:
initContainers:
- name: ${APP_NAME}-init
image: busybox
command: [ 'mkdir', '-p', "/data/logs" ]
command: [ 'mkdir', '-p', "/data/logs/gc" ]
volumeMounts:
- name: ${APP_NAME}-volume
mountPath: /data
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment