SEC-2097: Add Tomcat Gradle plugin

This commit is contained in:
Rob Winch 2013-08-05 16:22:33 -05:00
parent 343a76de13
commit 1f86d5dad9
12 changed files with 46 additions and 98 deletions

View File

@ -8,6 +8,7 @@ buildscript {
classpath("org.springframework.build.gradle:propdeps-plugin:0.0.3")
classpath("org.springframework.build.gradle:docbook-reference-plugin:0.2.7")
classpath("org.springframework.build.gradle:bundlor-plugin:0.1.2")
classpath("org.gradle.api.plugins:gradle-tomcat-plugin:0.9.8")
}
}
@ -76,6 +77,8 @@ configure(subprojects - coreModuleProjects) {
}
configure(javaProjects) {
ext.TOMCAT_GRADLE = "$rootDir/gradle/tomcat.gradle"
ext.WAR_SAMPLE_GRADLE = "$rootDir/gradle/war-sample.gradle"
apply from: "$rootDir/gradle/javaprojects.gradle"
apply from: "$rootDir/gradle/release-checks.gradle"
apply from: "$rootDir/gradle/maven-deployment.gradle"

10
gradle/tomcat.gradle Normal file
View File

@ -0,0 +1,10 @@
apply plugin: 'tomcat'
dependencies {
def tomcatVersion = '7.0.42'
tomcat "org.apache.tomcat.embed:tomcat-embed-core:${tomcatVersion}",
"org.apache.tomcat.embed:tomcat-embed-logging-juli:${tomcatVersion}"
tomcat("org.apache.tomcat.embed:tomcat-embed-jasper:${tomcatVersion}") {
exclude group: 'org.eclipse.jdt.core.compiler', module: 'ecj'
}
}

6
gradle/war-sample.gradle Normal file
View File

@ -0,0 +1,6 @@
apply plugin: 'war'
apply from: TOMCAT_GRADLE
sonarRunner {
skipProject = true
}

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'concurrency'
}
}
war {
baseName = "concurrency"
}
dependencies {

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'helloworld'
}
}
war {
baseName = "helloworld"
}
dependencies {

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'inmemory'
}
}
war {
baseName = "inmemory"
}
dependencies {

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'jdbc'
}
}
war {
baseName = "jdbc"
}
dependencies {

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'ldap'
}
}
war {
baseName = "ldap"
}
dependencies {

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'openid'
}
}
war {
baseName = "openid"
}
dependencies {

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'preauth'
}
}
war {
baseName = "preauth"
}
dependencies {

View File

@ -1,15 +1,7 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
}
eclipse {
wtp {
component {
contextPath = 'rememberme'
}
}
war {
baseName = "rememberme"
}
dependencies {

View File

@ -1,16 +1,9 @@
apply plugin: 'war'
apply from: WAR_SAMPLE_GRADLE
sonarRunner {
skipProject = true
war {
baseName = "x509"
}
eclipse {
wtp {
component {
contextPath = 'x509'
}
}
}
dependencies {