forked from backendDev7/NBE2_1_Se7enStarZ
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
83 lines (66 loc) · 2.25 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
plugins {
id 'java'
id 'org.springframework.boot' version '3.3.3'
id 'io.spring.dependency-management' version '1.1.6'
id 'com.github.node-gradle.node' version '3.0.1'
}
group = 'deu.ex'
version = '0.0.1-SNAPSHOT'
node {
version = '20.17.0' // 사용하려는 Node.js 버전
npmVersion = '10.8.3' // 사용하려는 npm 버전
download = true // Gradle이 자동으로 Node.js를 다운로드하게 설정
}
task npmBuild(type: NpmTask) {
args = ['run', 'build'] // 'build'는 React의 빌드 스크립트
}
// 백엔드 빌드에 프론트엔드 빌드를 포함
bootJar {
dependsOn npmBuild
from("build/") {
into 'static' // 빌드된 파일을 백엔드에서 서빙할 위치
}
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(17)
}
}
configurations {
compileOnly {
extendsFrom annotationProcessor
}
}
repositories {
mavenCentral()
}
dependencies {
implementation 'net.coobird:thumbnailator:0.4.20'
implementation 'org.springframework.boot:spring-boot-starter-data-jpa:3.3.2'
implementation 'org.springframework.boot:spring-boot-starter-validation'
implementation 'com.querydsl:querydsl-jpa:5.1.0:jakarta'
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'mysql:mysql-connector-java:8.0.33'
implementation 'com.querydsl:querydsl-jpa:5.1.0:jakarta'
implementation 'com.zaxxer:HikariCP:5.1.0'
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.6.0'
compileOnly 'org.projectlombok:lombok'
developmentOnly 'org.springframework.boot:spring-boot-devtools'
runtimeOnly 'com.mysql:mysql-connector-j'
annotationProcessor (
'jakarta.persistence:jakarta.persistence-api',
'jakarta.annotation:jakarta.annotation-api',
'com.querydsl:querydsl-apt:5.1.0:jakarta',
'org.projectlombok:lombok'
)
testImplementation 'org.springframework.boot:spring-boot-starter-test'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
testImplementation 'org.projectlombok:lombok'
testAnnotationProcessor 'org.projectlombok:lombok'
// https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.11.0'
}
tasks.named('test') {
useJUnitPlatform()
}