kos-mock CORS 설정 추가: Spring Boot 모범사례 적용으로 크로스 오리진 요청 지원

- SecurityConfig에 CorsConfigurationSource 빈 추가
- 모든 HTTP 메소드 지원 (GET, POST, PUT, DELETE, PATCH, OPTIONS, HEAD)
- 환경변수 기반 Origin 패턴 설정 (개발환경: *, 프로덕션: 구체적 도메인)
- Preflight 요청 캐시 및 노출 헤더 설정
- application.yml에 CORS 설정 블록 추가

🔧 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
hiondal
2025-09-11 13:07:13 +09:00
parent e4f3c32c8a
commit 04b3eba6c6
2 changed files with 51 additions and 0 deletions
@@ -68,6 +68,10 @@ logging:
file:
name: logs/kos-mock-service.log
# CORS 설정
cors:
allowed-origins: ${CORS_ALLOWED_ORIGINS:*}
# Swagger/OpenAPI
springdoc:
api-docs: