gradle-tomcat-plugin
gradle-tomcat-plugin copied to clipboard
RFE: Support multi web apps
Currently (as of 2.2.4) it is only possible to run a single web app. However there are use cases where multiple web apps should be deployed into Tomcat. It would be great if such a feature was supported by gradle-tomcat-plugin
. This is similar to Multiple web-apps provided by https://github.com/akhikhl/gretty plugin.
I was thinking that this could be achieved by adding webapps
configuration block, e.g.:
tomcat {
httpPort = 8090
httpsPort = 8091
enableSSL = true
webapps {
webapp {
reloadable=true
contextPath= 'sample-app1'
webDefaultXml=...
additionalRuntimeResources=...
}
webapp {
reloadable=false
contextPath= 'sample-app2'
webDefaultXml=...
additionalRuntimeResources=...
}
}
}
Each webapp
then will contain all web app specific configuration and tomcat
will contain Tomcat configuration. For compatibility it is probably makes sense to still support old way of configuring single app as before.