-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
126 lines (98 loc) · 4.28 KB
/
Copy pathbuild.gradle.kts
File metadata and controls
126 lines (98 loc) · 4.28 KB
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
val javaVersion = JavaLanguageVersion.of(21)
val tomcatVersion = "11.0.22"
val tilleggsstønaderLibsVersion = "2026.02.12-15.24.c553aa73162e"
val tilleggsstønaderKontrakterVersion = "2026.06.30-13.27.1d10c6fbe398"
val familieProsesseringVersion = "2.20260526102747_ed05f71"
val tokenSupportVersion = "6.0.10"
val wiremockVersion = "3.0.1"
val testcontainerVersion = "1.21.4"
group = "no.nav.tilleggsstonader.soknad"
version = "1.0.0"
plugins {
application
kotlin("jvm") version "2.3.21"
id("com.diffplug.spotless") version "8.7.0"
id("com.github.ben-manes.versions") version "0.54.0"
id("se.patrikerdes.use-latest-versions") version "0.2.19"
id("org.springframework.boot") version "4.1.0"
id("io.spring.dependency-management") version "1.1.7"
kotlin("plugin.spring") version "2.3.21"
}
repositories {
mavenCentral()
mavenLocal()
maven("https://jitpack.io")
maven {
url = uri("https://github-package-registry-mirror.gc.nav.no/cached/maven-release")
}
}
apply(plugin = "com.diffplug.spotless")
spotless {
kotlin {
ktlint("1.8.0")
}
}
// Spring 4.0.5 kommer tomcat v11.0.20, som er utsatt for bla. CWE-532
ext["tomcat.version"] = tomcatVersion
configurations.all {
resolutionStrategy {
failOnNonReproducibleResolution()
}
}
dependencies {
// Spring
implementation("org.springframework.boot:spring-boot-starter-web")
implementation("org.springframework.boot:spring-boot-starter-actuator")
implementation("org.springframework.boot:spring-boot-starter-validation")
implementation("tools.jackson.module:jackson-module-kotlin")
implementation("org.jetbrains.kotlin:kotlin-reflect")
implementation("org.springframework.boot:spring-boot-starter-data-jdbc")
implementation("org.springframework.boot:spring-boot-starter-flyway")
implementation("org.postgresql:postgresql")
implementation("org.flywaydb:flyway-database-postgresql")
// Logging
implementation("net.logstash.logback:logstash-logback-encoder:9.0")
implementation("io.micrometer:micrometer-registry-prometheus")
implementation("no.nav.familie:prosessering-core:$familieProsesseringVersion")
implementation("no.nav.familie:prosessering-web-nav-token-support:$familieProsesseringVersion")
// Tillegggsstønader libs
implementation("no.nav.tilleggsstonader-libs:util:$tilleggsstønaderLibsVersion")
implementation("no.nav.tilleggsstonader-libs:log:$tilleggsstønaderLibsVersion")
implementation("no.nav.tilleggsstonader-libs:http-client:$tilleggsstønaderLibsVersion")
implementation("no.nav.tilleggsstonader-libs:sikkerhet:$tilleggsstønaderLibsVersion")
implementation("no.nav.tilleggsstonader.kontrakter:kontrakter-felles:$tilleggsstønaderKontrakterVersion")
// Kafka
implementation("org.springframework.boot:spring-boot-starter-kafka")
implementation("no.nav.tms.varsel:kotlin-builder:2.2.0")
// Test
testImplementation("org.springframework.boot:spring-boot-starter-test")
// Kun for å kunne bruke WebTestClient. Kan fjernes og erstattes av RestTestClient i spring-boot 4
testImplementation("org.springframework.boot:spring-boot-resttestclient")
testImplementation("com.github.tomakehurst:wiremock-jre8-standalone:$wiremockVersion")
testImplementation("io.mockk:mockk:1.14.11")
testImplementation("org.testcontainers:postgresql:$testcontainerVersion")
testImplementation("no.nav.security:token-validation-spring-test:$tokenSupportVersion")
testImplementation("no.nav.tilleggsstonader-libs:test-util:$tilleggsstønaderLibsVersion")
// Transitiv avhengighet fra mock-oauth2-server -> bcpix. Disse under er definert som dynamisk versjon, noe bygget vårt ikke vil ha noe av
testImplementation("org.bouncycastle:bcutil-jdk18on:1.84")
testImplementation("org.bouncycastle:bcprov-jdk18on:1.84")
}
kotlin {
jvmToolchain(javaVersion.asInt())
compilerOptions {
freeCompilerArgs.add("-Xjsr305=strict")
freeCompilerArgs.add("-Xannotation-default-target=param-property")
}
}
application {
mainClass.set("no.nav.tilleggsstonader.soknad.AppKt")
}
if (project.hasProperty("skipLint")) {
gradle.startParameter.excludedTaskNames += "spotlessKotlinCheck"
}
tasks.test {
useJUnitPlatform()
}
tasks.bootJar {
archiveFileName.set("app.jar")
}