Skip to content

Commit

Permalink
setup visualvm
Browse files Browse the repository at this point in the history
  • Loading branch information
Peter Park committed Oct 10, 2024
1 parent d31f717 commit cfca564
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ build:
cd api && ./gradlew clean build

test: build
docker-comopse -f docker-compose-local.yml up --build
docker-compose -f docker-compose-local.yml up --build

deploy: build
docker-compose -f docker-compose-prod.yml up --build
Expand Down
13 changes: 12 additions & 1 deletion api/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,16 @@ FROM openjdk:21-jdk-slim
# JAR 파일을 /app 디렉토리에 복사합니다.
COPY build/libs/*.jar /app/myapp.jar

# JMX 및 RMI 관련 환경 변수 설정
ENV JAVA_OPTS="-Dcom.sun.management.jmxremote \
-Dcom.sun.management.jmxremote.port=9010 \
-Dcom.sun.management.jmxremote.rmi.port=9010 \
-Dcom.sun.management.jmxremote.authenticate=false \
-Dcom.sun.management.jmxremote.ssl=false \
-Djava.rmi.server.hostname=0.0.0.0 \
-Dcom.sun.management.jmxremote.local.only=false \
-Djava.rmi.server.port=1099 \
-Xms512m -Xmx512m"

# 애플리케이션을 실행합니다.
ENTRYPOINT ["java", "-jar", "/app/myapp.jar"]
ENTRYPOINT ["sh", "-c", "java $JAVA_OPTS -jar /app/myapp.jar"]
12 changes: 0 additions & 12 deletions docker-compose-kibana.yml

This file was deleted.

2 changes: 2 additions & 0 deletions docker-compose-local.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ services:
build: api
ports:
- "8081:8081"
- "9010:9010"
- "1099:1099"

# web:
# build: ./web
Expand Down

0 comments on commit cfca564

Please sign in to comment.