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
Providing an update to this question.
Tomcat 7 has changed it's manager API.
Please refer to: Manager commands
Following new URL pattern :
http://{host}:{port}/manager/text/{command}?{parameters}
Example
curl -T "myapp.war" "http://manager:manager@localhost:8080/manager/text/deploy?path=/myapp&update=true"
Security
Keep in mind the server must be able to accept your remote IP. This is a sample configuration:
This is an optional setting and isn't required but having Cross domain role and proper manager credentials is a must.
Tomcat 8 - the same rules apply as Tomcat 7. Same commands.
Here is a full documentation:
http://tomcat.apache.org/tomcat-8.0-doc/manager-howto.html