73 lines
2.3 KiB
Groovy
73 lines
2.3 KiB
Groovy
plugins {
|
|
id 'java'
|
|
id 'org.springframework.boot' version '3.5.13'
|
|
id 'io.spring.dependency-management' version '1.1.7'
|
|
id 'eclipse'
|
|
}
|
|
|
|
group = 'com.goi'
|
|
version = '0.0.1-SNAPSHOT'
|
|
description = 'security'
|
|
|
|
java {
|
|
toolchain {
|
|
// Java 17 -> 21
|
|
languageVersion = JavaLanguageVersion.of(21)
|
|
}
|
|
}
|
|
|
|
// Lombok: annotationProcessor 산출물을 compileOnly 컴파일 시에도 보이게 함
|
|
configurations {
|
|
compileOnly {
|
|
extendsFrom annotationProcessor
|
|
}
|
|
}
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
// template:layered-architecture-template:1.0.0-SNAPSHOT 같은 사내/로컬 산출물 해석용
|
|
// 기존 Maven 빌드 때 ~/.m2 에 install 된 아티팩트를 그대로 사용합니다.
|
|
mavenLocal()
|
|
}
|
|
|
|
ext {
|
|
// Spring Boot 가 관리하지 않는 의존성들의 버전을 한곳에 모아둠
|
|
jjwtVersion = '0.11.5'
|
|
springdocVersion = '2.8.17' // Spring Boot 3.5 대응 (기존 2.1.0 은 3.5에서 동작 불가)
|
|
}
|
|
|
|
dependencies {
|
|
// ---- Spring Boot starters (버전은 BOM 이 관리) ----
|
|
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
|
|
implementation 'org.springframework.boot:spring-boot-starter-security'
|
|
implementation 'org.springframework.boot:spring-boot-starter-web'
|
|
implementation 'org.springframework.boot:spring-boot-starter-validation'
|
|
|
|
// ---- OpenAPI / Swagger UI ----
|
|
implementation "org.springdoc:springdoc-openapi-starter-webmvc-ui:${springdocVersion}"
|
|
|
|
// ---- JWT (jjwt) ----
|
|
implementation "io.jsonwebtoken:jjwt-api:${jjwtVersion}"
|
|
runtimeOnly "io.jsonwebtoken:jjwt-impl:${jjwtVersion}"
|
|
runtimeOnly "io.jsonwebtoken:jjwt-jackson:${jjwtVersion}"
|
|
|
|
// ---- DB 드라이버 (런타임 전용) ----
|
|
runtimeOnly 'org.postgresql:postgresql'
|
|
|
|
// ---- Lombok ----
|
|
compileOnly 'org.projectlombok:lombok'
|
|
annotationProcessor 'org.projectlombok:lombok'
|
|
|
|
// ---- @ConfigurationProperties 메타데이터 생성기 ----
|
|
annotationProcessor 'org.springframework.boot:spring-boot-configuration-processor'
|
|
|
|
// ---- Test ----
|
|
testImplementation 'org.springframework.boot:spring-boot-starter-test'
|
|
testImplementation 'org.springframework.security:spring-security-test'
|
|
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
|
|
}
|
|
|
|
tasks.named('test') {
|
|
useJUnitPlatform()
|
|
}
|