forked from eventuate-foundation/eventuate-common
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
124 lines (103 loc) · 3.65 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
buildscript {
repositories {
mavenCentral()
eventuateMavenRepoUrl.split(',').each { repoUrl -> maven { url repoUrl } }
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:$springBootPluginVersion")
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.5'
classpath "com.avast.gradle:gradle-docker-compose-plugin:$dockerComposePluginVersion"
classpath "io.eventuate.plugins.gradle:eventuate-plugins-gradle-publish:$eventuatePluginsGradleVersion"
}
}
plugins {
id "com.github.hierynomus.license" version "0.12.1"
}
apply plugin: 'docker-compose'
apply plugin: "io.eventuate.plugins.gradle.publish.EventuatePublish"
apply plugin: "io.eventuate.plugins.gradle.publish.EventuatePublishDockerImages"
allprojects {
group = "io.eventuate.common"
}
projects {
license {
header rootProject.file('src/license/HEADER')
}
}
subprojects {
sourceCompatibility = 1.8
targetCompatibility = 1.8
repositories {
mavenCentral()
jcenter()
eventuateMavenRepoUrl.split(',').each { repoUrl -> maven { url repoUrl } }
}
dependencies {
testCompile "junit:junit:4.12"
}
}
task aggregatedTestReport(type: TestReport) {
destinationDir = file("$buildDir/reports/allTests")
// Include the results from the 'test' task in all subprojects
reportOn subprojects*.test
}
gradle.projectsEvaluated {
task aggregateJavaDocs(type: Javadoc) {
description = 'Aggregates Javadoc API documentation of all subprojects.'
group = JavaBasePlugin.DOCUMENTATION_GROUP
dependsOn subprojects.findAll { subproject -> subproject.plugins.hasPlugin(PublicModulePlugin) }.javadoc
source subprojects.findAll { subproject -> subproject.plugins.hasPlugin(PublicModulePlugin) }.javadoc.source
destinationDir file("$buildDir/docs/javadoc")
classpath = files(subprojects.findAll { subproject -> subproject.plugins.hasPlugin(PublicModulePlugin) }.javadoc.classpath)
}
}
dockerCompose {
removeOrphans = true
mysql {
projectName = null
useComposeFiles = ["docker-compose-mysql.yml"]
removeContainers = project.ext.removeContainers
}
mysqljson {
projectName = null
useComposeFiles = ["docker-compose-mysql-json.yml"]
removeContainers = project.ext.removeContainers
}
mariadb {
projectName = null
useComposeFiles = ["docker-compose-mariadb.yml"]
removeContainers = project.ext.removeContainers
}
mariadbjson {
projectName = null
useComposeFiles = ["docker-compose-mariadb-json.yml"]
removeContainers = project.ext.removeContainers
}
postgres {
projectName = null
useComposeFiles = ["docker-compose-postgres.yml"]
removeContainers = project.ext.removeContainers
}
postgresjson {
projectName = null
useComposeFiles = ["docker-compose-postgres-json.yml"]
removeContainers = project.ext.removeContainers
}
mssql {
projectName = null
useComposeFiles = ["docker-compose-mssql.yml"]
removeContainers = project.ext.removeContainers
}
mssqljson {
projectName = null
useComposeFiles = ["docker-compose-mssql-json.yml"]
removeContainers = project.ext.removeContainers
}
publish {
environment.put "DOCKER_IMAGE_TAG", dockerImageTag
projectName = null
useComposeFiles = ["docker-compose-mysql.yml", "docker-compose-mssql.yml",
"docker-compose-postgres.yml", "docker-compose-mariadb.yml", ]
removeContainers = project.ext.removeContainers
}
}