From 81b69caa99243d3229b8c15789efce098a40cdfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?dean=5B=EB=B0=B1=EB=B3=91=EB=82=A8=5D?= Date: Tue, 10 Mar 2026 16:00:23 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9A=B4=EC=98=81=ED=99=98=EA=B2=BD=EC=B2=98?= =?UTF-8?q?=EB=A6=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/application-dev.yml | 11 -------- src/main/resources/application-prod.yml | 24 ++++++----------- src/main/resources/application.yml | 35 ++----------------------- src/test/resources/application.yml | 20 -------------- 4 files changed, 10 insertions(+), 80 deletions(-) diff --git a/src/main/resources/application-dev.yml b/src/main/resources/application-dev.yml index d0845cb..b1ff27f 100644 --- a/src/main/resources/application-dev.yml +++ b/src/main/resources/application-dev.yml @@ -16,7 +16,6 @@ spring: datasource: url: jdbc:postgresql://192.168.2.127:15432/kamco_training_db -# url: jdbc:postgresql://localhost:15432/kamco_training_db username: kamco_training_user password: kamco_training_user_2025_!@# hikari: @@ -47,9 +46,6 @@ springdoc: member: init_password: kamco1234! -swagger: - local-port: 9080 - file: sync-root-dir: /app/original-images/ sync-tmp-dir: ${file.sync-root-dir}tmp/ @@ -71,10 +67,3 @@ train: shmSize: 16g ipcHost: true -# CORS 설정 (개발 환경) -cors: - allowed-origins: - - https://kamco.training-dev.gs.dabeeo.com - - http://localhost:3002 - - http://192.168.2.109:3002 - - http://192.168.2.109:7100 diff --git a/src/main/resources/application-prod.yml b/src/main/resources/application-prod.yml index c8b297c..cba2ed3 100644 --- a/src/main/resources/application-prod.yml +++ b/src/main/resources/application-prod.yml @@ -4,19 +4,16 @@ spring: on-profile: prod jpa: - show-sql: true + show-sql: false # 운영 환경에서는 성능을 위해 비활성화 hibernate: ddl-auto: validate properties: hibernate: - default_batch_fetch_size: 100 # ✅ 성능 - N+1 쿼리 방지 - order_updates: true # ✅ 성능 - 업데이트 순서 정렬로 데드락 방지 - use_sql_comments: true # ⚠️ 선택 - SQL에 주석 추가 (디버깅용) - format_sql: true # ⚠️ 선택 - SQL 포맷팅 (가독성) + default_batch_fetch_size: 100 # N+1 쿼리 방지 + order_updates: true # 업데이트 순서 정렬로 데드락 방지 datasource: url: jdbc:postgresql://kamco-cd-train-db:5432/kamco_training_db - # url: jdbc:postgresql://localhost:15432/kamco_training_db username: kamco_training_user password: kamco_training_user_2025_!@# hikari: @@ -31,13 +28,14 @@ spring: default-timeout: 300 # 5분 트랜잭션 타임아웃 jwt: - secret: "kamco_token_dev_dfc6446d-68fc-4eba-a2ff-c80a14a0bf3a" + # ⚠️ 운영 환경에서는 반드시 별도의 강력한 시크릿 키를 사용하세요 + secret: "kamco_token_prod_CHANGE_THIS_TO_SECURE_SECRET_KEY" access-token-validity-in-ms: 86400000 # 1일 refresh-token-validity-in-ms: 604800000 # 7일 token: - refresh-cookie-name: kamco # 개발용 쿠키 이름 - refresh-cookie-secure: false # 로컬 http 테스트면 false + refresh-cookie-name: kamco + refresh-cookie-secure: true # HTTPS 환경에서 필수 springdoc: swagger-ui: @@ -46,9 +44,6 @@ springdoc: member: init_password: kamco1234! -swagger: - local-port: 9080 - file: sync-root-dir: /app/original-images/ sync-tmp-dir: ${file.sync-root-dir}tmp/ @@ -70,8 +65,5 @@ train: shmSize: 16g ipcHost: true -# CORS 설정 (운영 환경) -cors: - allowed-origins: - - https://train-kamco.com + diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index c94d8ef..f540f45 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -10,10 +10,6 @@ spring: datasource: driver-class-name: org.postgresql.Driver hikari: - jdbc: - time_zone: UTC - batch_size: 50 - # 권장 설정 minimum-idle: 2 maximum-pool-size: 2 connection-timeout: 20000 @@ -21,18 +17,11 @@ spring: max-lifetime: 1800000 leak-detection-threshold: 60000 - data: - redis: - host: localhost - port: 6379 - password: jpa: hibernate: ddl-auto: update # 스키마 자동 관리 활성화 properties: hibernate: - hbm2ddl: - auto: update javax: persistence: validation: @@ -55,11 +44,8 @@ logging: security: INFO root: INFO -# CORS 설정 -cors: - allowed-origins: - - http://localhost:3000 - - http://localhost:3002 + + # actuator management: health: @@ -83,20 +69,3 @@ management: exposure: include: - "health" - -# GeoJSON 파일 모니터링 설정 -geojson: - monitor: - watch-directory: ~/geojson/upload - processed-directory: ~/geojson/processed - error-directory: ~/geojson/error - temp-directory: /tmp/geojson_extract - cron-expression: "0/30 * * * * *" # 매 30초마다 실행 - supported-extensions: - - zip - - tar - - tar.gz - - tgz - max-file-size: 104857600 # 100MB - - diff --git a/src/test/resources/application.yml b/src/test/resources/application.yml index dd3182d..bf7b307 100644 --- a/src/test/resources/application.yml +++ b/src/test/resources/application.yml @@ -18,12 +18,6 @@ spring: max-lifetime: 1800000 leak-detection-threshold: 60000 - data: - redis: - host: localhost - port: 6379 - password: - jpa: hibernate: ddl-auto: none # 테스트 환경에서는 DDL 자동 생성/수정 비활성화 @@ -69,20 +63,6 @@ management: include: - "health" -geojson: - monitor: - watch-directory: ~/geojson/upload - processed-directory: ~/geojson/processed - error-directory: ~/geojson/error - temp-directory: /tmp/geojson_extract - cron-expression: "0/30 * * * * *" - supported-extensions: - - zip - - tar - - tar.gz - - tgz - max-file-size: 104857600 - jwt: secret: "test_secret_key_for_testing_purposes_only" access-token-validity-in-ms: 86400000