clean up build

parent 45f49df6
......@@ -42,12 +42,7 @@ apply plugin: "idea"
apply plugin: "com.google.cloud.tools.jib"
dependencies {
def external = project.hasProperty("external") && Boolean.valueOf(project.getProperty("external"))
if (external) {
compile "org.apereo.cas:cas-server-webapp:${casServerVersion}"
} else {
compile "org.apereo.cas:cas-server-webapp${project.appServer}:${casServerVersion}"
}
compile "org.apereo.cas:cas-server-webapp${project.appServer}:${casServerVersion}"
// Other CAS dependencies/modules may be listed here...
}
......
......@@ -2,8 +2,9 @@
cas.version=6.0.0-RC4-SNAPSHOT
springBootVersion=2.1.0.RELEASE
appServer=-tomcat
external=false
# Use -jetty, -undertow to other containers
# Or blank if you want to deploy to an external container
appServer=
executable=false
gradleVersion=5.0
......
......@@ -246,13 +246,6 @@ def isRunningCasServerSnapshot(casServerVersion) {
return "${casServerVersion}".contains("-SNAPSHOT")
}
task setExternal(group: "build", description: "Configure the project to run in an external container") {
doFirst {
project.setProperty("external", "true")
logger.info "Configuring the project as external"
}
}
task downloadTomcat(type: Download) {
def tomcatMajorVersion = "${tomcatVersion}".substring(0, "${tomcatVersion}".indexOf("."))
def downloadFile = "https://www.apache.org/dist/tomcat/tomcat-${tomcatMajorVersion}/v${tomcatVersion}/bin/apache-tomcat-${tomcatVersion}.zip"
......@@ -279,7 +272,7 @@ task shutdownTomcat(type:Exec) {
}
task tomcatDeploy(type:Exec) {
dependsOn setExternal, build, downloadTomcat, unzipTomcat, shutdownTomcat
dependsOn build, downloadTomcat, unzipTomcat, shutdownTomcat
doFirst {
Files.copy(Paths.get(bootWar.archivePath.canonicalPath),
......@@ -301,7 +294,7 @@ tail {
}
}
build.mustRunAfter(setExternal, setExecutable)
build.mustRunAfter(setExecutable)
unzipTomcat.mustRunAfter(downloadTomcat)
shutdownTomcat.mustRunAfter(unzipTomcat)
tomcatDeploy.mustRunAfter(shutdownTomcat).finalizedBy(tail)
tomcatDeploy.mustRunAfter(shutdownTomcat).finalizedBy(tail)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment