I\'m writing a shell script to auto deploy/undeploy using the tomcat manager.
Following the instructions on http://tomcat.apache.org/tomcat-6.0-doc/manager-howto.htm
This way is working for me on Tomcat 6 (See jevelopers answer for tomcat 7):
curl --upload-file "http://:@:/manager/deploy?path=/&update=true"
Example:
curl --upload-file target\debug.war "http://tomcat:tomcat@localhost:8088/manager/deploy?path=/debug&update=true"
Very easy peasy. Output is like this:
OK - Undeployed application at context path /debug
OK - Deployed application at context path /debug