maven to copy jar, war to tomcat webapp

gudii9
gudii9 used Ask the Experts™
on
Hi,

I am following below link

http://evgeny-goldin.com/wiki/Copy-maven-plugin


I wonder how can i copy generated jar, war from maven clean command(mvn clean install ) automatically to tomcat webapp directory. please advise
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
IT Business Systems Analyst / Software Developer
Top Expert 2015
Commented:
You should be able to use the copy plugin to do this, however if you want to be flexible and be able to deploy your webapp to remote tomcat's to (and handle automatically starting the webapp, etc, etc) you could look at the Cargo maven plugin. There are some examples here... https://weblogs.java.net/blog/johnsmart/archive/2009/12/28/automated-deployment-cargo-and-maven-short-primer

Author

Commented:
however if you want to be flexible and be able to deploy your webapp to remote tomcat's

does cargo maven works with local tomcat as well(not remote in my case with windows laptop with eclipse and tomcat on same laptop)
please advise
mccarlIT Business Systems Analyst / Software Developer
Top Expert 2015

Commented:
Yes it can work just fine with a local Tomcat too.

Author

Commented:
sure. I will try

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial