-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
80 lines (66 loc) · 2.79 KB
/
build.gradle.kts
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
import org.springframework.boot.gradle.tasks.bundling.BootBuildImage
val springCloudVersion by extra { "2023.0.3" }
val springBootVersion by extra { "3.3.3" }
plugins {
java
id("org.springframework.boot") version "3.3.3"
id("io.spring.dependency-management") version "1.1.5"
id("org.springframework.boot.aot") version "3.3.3"
// id("org.graalvm.buildtools.native") version "0.10.2"
}
allprojects {
group = "pl.owolny"
version = "1.0"
}
allprojects {
repositories {
mavenCentral()
}
}
subprojects {
apply(plugin = "java")
apply(plugin = "org.springframework.boot")
apply(plugin = "io.spring.dependency-management")
apply(plugin = "org.springframework.boot.aot")
// apply(plugin = "org.graalvm.buildtools.native")
java.sourceCompatibility = JavaVersion.VERSION_21
dependencies {
implementation("org.springframework.boot:spring-boot-starter")
implementation("org.springframework.boot:spring-boot-starter-aop")
implementation("org.springframework.cloud:spring-cloud-starter-netflix-eureka-client")
implementation("org.springframework.boot:spring-boot-starter-actuator")
developmentOnly("org.springframework.boot:spring-boot-devtools")
testImplementation("org.springframework.boot:spring-boot-starter-test")
compileOnly("org.projectlombok:lombok")
annotationProcessor("org.projectlombok:lombok")
implementation("org.mapstruct:mapstruct:1.5.5.Final")
annotationProcessor("org.mapstruct:mapstruct-processor:1.5.5.Final")
implementation("org.springframework.boot:spring-boot-starter-amqp")
// Observability
implementation("com.github.loki4j:loki-logback-appender:1.6.0-m1")
implementation("io.micrometer:micrometer-registry-prometheus")
implementation("io.micrometer:micrometer-tracing-bridge-brave")
implementation("io.zipkin.reporter2:zipkin-reporter-brave")
}
dependencyManagement {
imports {
mavenBom("org.springframework.boot:spring-boot-dependencies:$springBootVersion")
mavenBom("org.springframework.cloud:spring-cloud-dependencies:$springCloudVersion")
}
}
tasks.withType<BootBuildImage> {
imageName = "vetther/${rootProject.name}-${project.name}"
environment.put("SPRING_PROFILES_ACTIVE", "cds")
environment.put("BP_JVM_CDS_ENABLED", "true")
environment.put("BP_SPRING_AOT_ENABLED", "true")
buildpacks = listOf("gcr.io/paketo-buildpacks/eclipse-openj9:latest", "paketo-buildpacks/java")
// builder.set("paketobuildpacks/builder-jammy-buildpackless-tiny")
// buildpacks.add("gcr.io/paketo-buildpacks/java")
}
configurations {
create("providedRuntime")
}
tasks.withType<Test> {
useJUnitPlatform()
}
}