Wednesday 15 September 2010

java - maven tomcat plugin configuration -


The application is deployed on the Tomcat root using the Maven plugin.

  & lt; Plugin & gt; & Lt; Group & gt; Org.codehaus.mojo & lt; / Group & gt; & Lt; ArtifactId & gt; Badge-Maven-plugin & lt; / ArtifactId> & Lt; Version & gt; 1.1 & lt; / Edition & gt; & Lt; Configuration & gt; & Lt; URL & gt; Http: //www.myhost.com: 8080 / Manager & lt; / URL & gt; & Lt; Server & gt; Tomcat6 & lt; / Server & gt; & Lt; Path & gt; / & Lt; / Path & gt; & Lt; ContextFile & gt; Src / home / tomcatconf / context.xml & lt; / ContextFile & gt; & Lt; Mode & gt; Reference & lt; / Mode & gt; & Lt; / Configuration & gt;   

The application is deployed on the root above but the problem is that the use of images, javascript and other PDF files (large size) from a folder "static" Being stored out of the application c: \ static \

Please suggest for the necessary configuration in pom.xml to access images like below.

You can get the embedded tomcat7 plugin like this:

  & Lt; Plugin & gt; & Lt; Group & gt; Org.apache.tomcat.maven & lt; / Group & gt; & Lt; ArtifactId & gt; Tomcat7-maven-plugin & lt; / ArtifactId> & Lt; Version & gt; 2.0 & lt; / Edition & gt; & Lt; / Plugin & gt;    

No comments:

Post a Comment