-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathbuild.gradle
87 lines (71 loc) · 2.43 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
84
85
86
87
import net.ltgt.gradle.errorprone.CheckSeverity
plugins {
id 'com.palantir.baseline' version '4.126.0' apply false
id 'org.inferred.processors' version '3.6.0'
id 'java'
id 'com.github.node-gradle.node' version '3.2.1'
id 'com.diffplug.spotless' version '6.3.0'
id 'com.palantir.docker-compose' version '0.32.0'
id 'org.jetbrains.kotlin.jvm' version "${kotlinVersion}" apply false
id 'org.jetbrains.kotlin.plugin.spring' version "${kotlinVersion}" apply false
id 'org.jetbrains.kotlin.plugin.jpa' version "${kotlinVersion}" apply false
id 'com.google.protobuf' version '0.8.18' apply false
id 'org.springframework.boot' version '2.6.4' apply false
id 'io.spring.dependency-management' version '1.0.11.RELEASE' apply false
}
allprojects {
group = 'org.hse'
version = '0.0.1-SNAPSHOT'
apply plugin: 'java'
apply plugin: 'com.diffplug.spotless'
apply plugin: 'com.palantir.baseline-idea'
apply plugin: 'com.palantir.baseline-error-prone'
sourceCompatibility = '17'
repositories {
mavenCentral()
}
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
kotlinOptions {
freeCompilerArgs = ["-Xjsr305=strict"]
jvmTarget = "17"
}
}
node {
version = '17.6.0'
npmVersion = '8.5.1'
download = true
npmInstallCommand = project.hasProperty("isCI") ? "ci" : "install"
}
spotless {
format 'misc', {
target '*.gradle', '*.md', '.gitignore', '*.json', '*.yaml', '*.sh'
targetExclude 'node_modules/*', 'package-lock.json'
trimTrailingWhitespace()
indentWithSpaces()
endWithNewline()
}
}
java {
tasks.withType(JavaCompile) {
options.errorprone {
check("Slf4jLogsafeArgs", CheckSeverity.OFF)
check("PreferSafeLoggableExceptions", CheckSeverity.OFF)
check("PreferSafeLogger", CheckSeverity.OFF)
check("PreferSafeLoggingPreconditions", CheckSeverity.OFF)
check("PreconditionsConstantMessage", CheckSeverity.OFF)
}
}
}
}
task buildProxyConfig(type: Exec) {
executable "scripts/dotenv.sh"
args "$projectDir/.env", "$projectDir/envoy.template.yaml", "$buildDir/envoy.yaml"
}
task buildDockerConfig(type: Exec) {
executable "scripts/dotenv.sh"
args "$projectDir/.env", "$projectDir/docker-compose.template.yaml", "$buildDir/docker-compose.yaml"
}
dockerCompose {
dockerComposeFile "$buildDir/docker-compose.yaml"
}
dockerComposeUp.dependsOn buildProxyConfig, buildDockerConfig