2013-12-10 19:06:59 +08:00
|
|
|
buildscript {
|
2014-01-15 19:23:07 +08:00
|
|
|
ext {
|
2015-12-17 21:15:14 +08:00
|
|
|
springBootVersion = '1.2.9.BUILD-SNAPSHOT'
|
2014-01-15 19:23:07 +08:00
|
|
|
}
|
2014-03-20 07:50:55 +08:00
|
|
|
repositories {
|
2014-03-26 07:00:55 +08:00
|
|
|
// NOTE: You should declare only repositories that you need here
|
2014-03-20 07:50:55 +08:00
|
|
|
mavenLocal()
|
2014-03-26 07:00:55 +08:00
|
|
|
mavenCentral()
|
|
|
|
maven { url "http://repo.spring.io/release" }
|
|
|
|
maven { url "http://repo.spring.io/milestone" }
|
|
|
|
maven { url "http://repo.spring.io/snapshot" }
|
2014-03-20 07:50:55 +08:00
|
|
|
}
|
|
|
|
dependencies {
|
|
|
|
classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
|
|
|
|
}
|
2013-12-10 19:06:59 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
apply plugin: 'java'
|
|
|
|
apply plugin: 'eclipse'
|
|
|
|
apply plugin: 'idea'
|
|
|
|
apply plugin: 'spring-boot'
|
|
|
|
|
|
|
|
jar {
|
2014-03-20 07:50:55 +08:00
|
|
|
baseName = 'spring-boot-sample-actuator'
|
|
|
|
version = '0.0.0'
|
2013-12-10 19:06:59 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
2014-03-26 07:00:55 +08:00
|
|
|
// NOTE: You should declare only repositories that you need here
|
2014-03-20 07:50:55 +08:00
|
|
|
mavenLocal()
|
|
|
|
mavenCentral()
|
2014-03-26 07:00:55 +08:00
|
|
|
maven { url "http://repo.spring.io/release" }
|
|
|
|
maven { url "http://repo.spring.io/milestone" }
|
|
|
|
maven { url "http://repo.spring.io/snapshot" }
|
2013-12-10 19:06:59 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
configurations {
|
|
|
|
insecure.exclude module: 'spring-boot-starter-security'
|
|
|
|
}
|
2014-03-19 19:31:34 +08:00
|
|
|
|
2014-03-20 07:50:55 +08:00
|
|
|
compile("org.springframework.boot:spring-boot-starter-actuator")
|
2014-05-13 22:40:55 +08:00
|
|
|
compile("org.springframework.boot:spring-boot-starter-jdbc")
|
2014-03-20 07:50:55 +08:00
|
|
|
compile("org.springframework.boot:spring-boot-starter-security")
|
|
|
|
compile("org.springframework.boot:spring-boot-starter-web")
|
2014-05-13 22:40:55 +08:00
|
|
|
compile("com.h2database:h2")
|
2014-05-15 16:15:35 +08:00
|
|
|
|
2014-03-20 07:50:55 +08:00
|
|
|
testCompile("org.springframework.boot:spring-boot-starter-test")
|
2014-03-19 19:31:34 +08:00
|
|
|
|
2014-03-20 07:50:55 +08:00
|
|
|
insecure configurations.runtime
|
2013-12-10 19:06:59 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
// Slightly odd requirement (package a jar file as an insecure app, exlcuding Spring Security)
|
|
|
|
// just to demonstrate the "customConfiguration" feature of the Boot gradle plugin.
|
|
|
|
springBoot {
|
|
|
|
customConfiguration = "insecure"
|
|
|
|
}
|
|
|
|
|
|
|
|
task wrapper(type: Wrapper) {
|
2014-03-20 07:50:55 +08:00
|
|
|
gradleVersion = '1.6'
|
2013-12-10 19:06:59 +08:00
|
|
|
}
|