-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle
163 lines (142 loc) · 5.59 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
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
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
buildscript {
ext {
springBootVersion = '2.1.5.RELEASE'
epagesRestDocsVersion = '0.9.5'
}
repositories {
mavenCentral()
jcenter()
maven { url "https://plugins.gradle.org/m2/" }
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
classpath("com.epages:restdocs-api-spec-gradle-plugin:${epagesRestDocsVersion}")
}
}
allprojects {
group = 'io.github.kaiso.lygeum'
version = '1.0.0'
}
subprojects {
if(it.name != 'ui') {
ext {
springBootVersion = '2.1.5.RELEASE'
}
repositories {
mavenCentral()
jcenter()
}
apply plugin : 'java'
apply plugin : 'eclipse'
apply plugin : 'org.springframework.boot'
apply plugin : 'io.spring.dependency-management'
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
bootJar.enabled = false
jar.enabled = true
ext['liquibase.version'] = '3.6.2'
ext['jaxb.version'] = '2.3.1'
ext['javax.el.version'] = '3.0.0'
ext['spring.security.oauth2.version'] = '2.3.3.RELEASE'
configurations.all {
exclude group: 'junit'
exclude group: 'org.codehaus.jackson'
}
eclipse {
classpath {
file {
whenMerged {
entries.removeAll { it.path.endsWith('junit-platform-launcher-1.3.1 jar') }
entries.removeAll { it.path.endsWith('junit-platform-commons-1.3.2.jar') }
}
}
}
}
dependencies {
implementation 'com.fasterxml.jackson.core:jackson-databind:2.9.6'
implementation 'com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:2.9.0'
implementation 'com.fasterxml.jackson.dataformat:jackson-dataformat-properties:2.9.0'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation group: 'org.springframework', name: 'spring-tx'
implementation group: 'org.springframework.security', name: 'spring-security-core'
implementation 'com.h2database:h2:1.4.200'
implementation group: 'org.postgresql', name: 'postgresql', version: '42.2.9'
implementation group: 'javax.persistence', name: 'javax.persistence-api', version: '2.2'
implementation group: 'org.hibernate', name: 'hibernate-core'
implementation group: 'org.springframework.data', name: 'spring-data-commons'
implementation group: 'org.springframework.data', name: 'spring-data-jpa'
implementation group: 'javax.xml.bind', name: 'jaxb-api', version: "${project.'jaxb.version'}"
implementation group: 'org.glassfish.jaxb', name: 'jaxb-runtime', version: "${project.'jaxb.version'}"
implementation group: 'javax.enterprise', name: 'cdi-api', version: '2.0'
implementation group: 'javax.validation', name: 'validation-api', version: '2.0.1.Final'
implementation group: 'javax.el', name: 'javax.el-api', version: "${project.'javax.el.version'}"
implementation group: 'org.glassfish', name: 'javax.el', version: "${project.'javax.el.version'}"
//Test dependencies
testImplementation 'org.jmockit:jmockit:1.47'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.6.2'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.6.2'
testRuntimeOnly group: 'org.junit.platform', name: 'junit-platform-engine', version: '1.6.2'
testRuntimeOnly group: 'org.junit.platform', name: 'junit-platform-commons', version: '1.6.2'
testRuntimeOnly group: 'org.springframework', name: 'spring-aspects'
testImplementation('org.springframework.boot:spring-boot-starter-test') {
exclude group: 'org.mockito', module: 'mockito-core'
exclude group: 'org.junit', module: 'junit'
}
testImplementation group: 'org.springframework.security', name: 'spring-security-test'
testImplementation group: 'org.assertj', name: 'assertj-core', version: '3.18.1'
}
test.doFirst {
def jmockitPath = "${classpath.find { it.name.contains("jmockit") }.absolutePath}"
def jmockitAgent = "-javaagent:${jmockitPath}"
println "Append to jvm args: ${jmockitAgent}"
jvmArgs "${jmockitAgent}"
useJUnitPlatform()
}
}
}
project(':loader') {
dependencies {
implementation project(':pers')
implementation project(':api')
implementation project(':core')
implementation project(':sec')
}
}
project(':api') {
apply plugin : 'com.epages.restdocs-api-spec'
dependencies {
implementation project(':core')
//Rest API documentation
testImplementation 'org.springframework.restdocs:spring-restdocs-mockmvc'
testImplementation "com.epages:restdocs-api-spec-mockmvc:${project.'epagesRestDocsVersion'}"
}
openapi3 {
server = 'https://localhost:5000'
title = 'The Lygeum server API'
description = 'This is the api documentation for the Lygeum configuration server'
version = "${project.'version'}"
outputDirectory = "${project.rootDir}/docs/assets"
outputFileNamePrefix = 'openapi'
format = 'yaml'
tagDescriptionsPropertiesFile = "src/test/resources/tags.yaml"
oauth2SecuritySchemeDefinition = {
flows = ['clientCredentials']
tokenUrl = 'https://localhost:5000/lygeum/auth/access_token'
}
}
postman {
title = 'The Lygeum server API'
version = "${project.'version'}"
baseUrl = 'https://localhost:5000'
}
}
project(':sec') {
dependencies {
implementation project(':core')
}
}
project(':pers') {
dependencies {
implementation project(':core')
}
}