This repository has been archived by the owner on Apr 5, 2022. It is now read-only.
/
build.gradle
80 lines (65 loc) · 1.76 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
buildscript {
repositories {
maven { url "http://repo.spring.io/libs-release" }
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:1.2.3.RELEASE")
}
}
version = '0.1.0'
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'spring-boot'
repositories {
mavenCentral()
maven { url "http://repo.spring.io/libs-release" }
}
dependencies {
compile("org.springframework.data:spring-yarn-boot:2.2.0.RELEASE")
}
compileJava {
sourceCompatibility=1.7
targetCompatibility=1.7
}
task clientJar(type: Jar) {
appendix = 'client'
baseName = 'yarn-boot-simple'
from sourceSets.main.output
exclude('**/appmaster/*')
exclude('**/container/*')
}
task appmasterJar(type: Jar) {
appendix = 'appmaster'
baseName = 'yarn-boot-simple'
from sourceSets.main.output
exclude('**/client/*')
exclude('**/container/*')
}
task containerJar(type: Jar) {
appendix = 'container'
baseName = 'yarn-boot-simple'
from sourceSets.main.output
exclude('**/appmaster/*')
exclude('**/client/*')
}
task clientBoot(type: BootRepackage, dependsOn: clientJar) {
withJarTask = clientJar
mainClass = 'hello.client.ClientApplication'
}
task appmasterBoot(type: BootRepackage, dependsOn: appmasterJar) {
withJarTask = appmasterJar
mainClass = 'hello.appmaster.AppmasterApplication'
}
task containerBoot(type: BootRepackage, dependsOn: containerJar) {
withJarTask = containerJar
mainClass = 'hello.container.ContainerApplication'
}
jar.enabled = false
bootRepackage.enabled = false
task bootJars
bootJars.dependsOn = [clientBoot, appmasterBoot, containerBoot]
build.dependsOn(bootJars)
task wrapper(type: Wrapper) {
gradleVersion = '2.2.1'
}