-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
148 lines (139 loc) · 5.96 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
buildscript {
ext {
// This map is by no means official. But it represents a quick
// sampling of what our services currently have.
bootToCloudMap = [
'2.3.12': 'Hoxton.SR12',
'2.3.11': 'Hoxton.SR11',
'2.3.10': 'Hoxton.SR11',
'2.3.9': 'Hoxton.SR10',
'2.3.8': 'Hoxton.SR9',
'2.3.7': 'Hoxton.SR9',
'2.3.6': 'Hoxton.SR9',
'2.3.5': 'Hoxton.SR9',
'2.3.4': 'Hoxton.SR8',
'2.3.3': 'Hoxton.SR7',
'2.3.2': 'Hoxton.SR6',
'2.2.13': 'Hoxton.SR9',
'2.2.12': 'Hoxton.SR9',
'2.2.11': 'Hoxton.SR9',
'2.2.10': 'Hoxton.SR8',
'2.2.9': 'Hoxton.SR6',
'2.2.8': 'Hoxton.SR5',
'2.2.7': 'Hoxton.SR4',
'2.2.6': 'Hoxton.SR3',
'2.2.5': 'Hoxton.SR2',
'2.2.4': 'Hoxton.SR1',
'2.1.15': 'Greenwich.SR6',
'2.1.14': 'Greenwich.SR5',
'2.1.13': 'Greenwich.SR5',
'2.1.12': 'Greenwich.SR4',
'2.1.11': 'Greenwich.SR4',
'2.1.10': 'Greenwich.SR3',
'2.1.9': 'Greenwich.SR3',
'2.1.8': 'Greenwich.SR3',
'2.1.7': 'Greenwich.SR2',
'2.1.5': 'Greenwich.SR1',
'2.1.4': 'Greenwich.SR1',
'2.1.3': 'Greenwich.SR1',
'2.1.2': 'Greenwich.RELEASE',
'2.0.8': 'Finchley.SR2',
'2.0.7': 'Finchley.SR2',
'2.0.6': 'Finchley.SR2',
'2.0.5': 'Finchley.SR1',
'2.0.4': 'Finchley.SR1',
'2.0.3': 'Finchley.RELEASE',
'2.0.2': 'Finchley.RELEASE',
'1.5.16' : 'Edgware.SR4',
'1.5.15' : 'Edgware.SR4',
'1.5.14' : 'Edgware.SR4',
'1.5.13' : 'Edgware.SR3',
'1.5.12' : 'Edgware.SR3',
'1.5.11' : 'Edgware.SR2',
'1.5.10' : 'Edgware.SR1',
'1.5.9' : 'Edgware.SR1',
'1.5.7' : 'Dalston.SR4',
'1.5.6' : 'Dalston.SR2',
'1.5.5' : 'Dalston.SR1',
'1.5.4' : 'Dalston.SR1',
'1.5.3' : 'Dalston.RELEASE',
'1.4.7' : 'Camden.SR6',
'1.4.4' : 'Camden.SR4'
]
springBootVersion = "${project.property('boot')}.RELEASE"
springCloudVersion = bootToCloudMap[project.property('boot')]
}
repositories {
mavenCentral()
}
dependencies {
classpath "org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}"
}
}
apply plugin: 'java'
apply plugin: 'org.springframework.boot'
apply plugin: 'io.spring.dependency-management'
group = 'com.allogy.spring'
version = '0.1-SNAPSHOT'
sourceCompatibility = 11
repositories {
mavenCentral()
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-actuator'
implementation 'org.springframework.boot:spring-boot-starter-data-elasticsearch'
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
implementation 'org.springframework.boot:spring-boot-starter-data-redis'
implementation 'org.springframework.boot:spring-boot-starter-data-mongodb'
implementation 'org.springframework.boot:spring-boot-starter-hateoas'
implementation 'org.springframework.boot:spring-boot-starter-jdbc'
implementation 'org.springframework.boot:spring-boot-starter-security'
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-validation'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'org.springframework.boot:spring-boot-starter-undertow'
implementation 'org.springframework.boot:spring-boot-starter-tomcat'
implementation 'org.springframework.boot:spring-boot-starter-cache'
implementation 'org.springframework.boot:spring-boot-starter-aop'
implementation 'org.flywaydb:flyway-core'
implementation 'org.springframework.cloud:spring-cloud-starter-config'
if(isSpringBoot2()) {
implementation 'org.springframework.cloud:spring-cloud-starter-netflix-eureka-client'
implementation 'org.springframework.cloud:spring-cloud-starter-netflix-hystrix'
implementation 'org.springframework.cloud:spring-cloud-starter-netflix-ribbon'
implementation 'org.springframework.cloud:spring-cloud-starter-netflix-zuul'
} else {
implementation 'org.springframework.cloud:spring-cloud-starter-eureka'
implementation 'org.springframework.cloud:spring-cloud-starter-hystrix'
implementation 'org.springframework.cloud:spring-cloud-starter-ribbon'
implementation 'org.springframework.cloud:spring-cloud-starter-zuul'
}
if(isSpringBoot2()) {
implementation 'org.springframework.session:spring-session-data-redis'
implementation 'org.springframework.session:spring-session-jdbc'
} else {
implementation 'org.springframework.session:spring-session'
}
runtimeOnly 'org.springframework.boot:spring-boot-devtools'
runtimeOnly 'mysql:mysql-connector-java'
runtimeOnly 'org.postgresql:postgresql'
compileOnly 'org.projectlombok:lombok'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
testImplementation 'org.springframework.security:spring-security-test'
if(isSpringBoot2()) {
testImplementation 'org.junit.jupiter:junit-jupiter-engine'
testImplementation 'org.junit.jupiter:junit-jupiter-params'
}
}
dependencyManagement {
imports {
mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}"
}
}
task springBootGet(dependsOn: ['clean', 'assemble', 'check'])
def isSpringBoot2() {
return springBootVersion.startsWith('2')
}
wrapper {
gradleVersion = '6.8.3'
}