Reputation: 4089
I'm using the gradle-tomcat-plugin to run tomcat on a simple web application. What Im trying to do is to change the root web application directory from src/main/webapp/
to WebContent/
tomcat {
httpPort = 8080
httpsPort = 8081
enableSSL = false
jasper {
uriroot = file('WebContent')
}
}
This is not working at all when I run gradle tomcatRun
and it still maps to src/main/webapp/
.
Any suggestions?
Upvotes: 2
Views: 647
Reputation: 33436
Configuring the web application directory in Gradle is independent of the configuration properties exposed by the Tomcat plugin. The plugin that sets the default web app directory to src/main/webapp
is the War plugin. To change this default directory assign a new value to the property webAppDirName
, as shown in the following example:
webAppDirName = 'WebContent'
Upvotes: 1