forked from podaac/swodlr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
68 lines (60 loc) · 1.93 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
plugins {
id 'org.springframework.boot' version '2.7.2'
id 'io.spring.dependency-management' version '1.0.12.RELEASE'
id 'application'
id 'jacoco'
id 'checkstyle'
id 'com.google.cloud.tools.jib' version '3.3.0'
}
group = 'gov.nasa.podaac.swodlr'
version = '0.0.1-alpha0'
sourceCompatibility = '17'
repositories {
mavenCentral()
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
implementation 'org.springframework.boot:spring-boot-starter-graphql'
implementation 'org.springframework.boot:spring-boot-starter-webflux'
implementation 'org.postgresql:postgresql:42.5.0'
implementation 'com.zaxxer:HikariCP:5.0.1'
developmentOnly 'org.springframework.boot:spring-boot-devtools'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
testImplementation 'org.springframework.graphql:spring-graphql-test'
testImplementation 'com.h2database:h2:2.1.214'
}
checkstyle {
toolVersion '10.3.4'
configFile = file('/google_checks.xml')
configProperties = [
'org.checkstyle.google.suppressionfilter.config': "$projectDir/config/checkstyle/suppressions.xml"
]
maxWarnings = 0
}
jib {
from {
image = 'eclipse-temurin:17-jre-alpine'
}
to {
image = "ghcr.io/podaac/swodlr-api:${version}"
def headRef = System.env.GITHUB_REF_NAME ? System.env.GITHUB_REF_NAME : ""
if (headRef.equals('develop') || headRef.equals('main')) {
tags = [headRef]
} else if (headRef.startsWith('release')) {
tags = ['rc']
}
}
container {
format = "OCI"
labels = [
'org.opencontainers.image.source': 'https://github.com/podaac/swodlr',
'org.opencontainers.image.licenses': 'Apache-2.0'
]
}
}
tasks.named('test') {
useJUnitPlatform()
}
tasks.named('check').configure {
dependsOn(tasks.named('jacocoTestReport'))
}