Restarting Tomcat from Tomcat itself

Posted by Jack on Stack Overflow See other posts from Stack Overflow or by Jack
Published on 2010-05-08T15:03:45Z Indexed on 2010/05/08 15:08 UTC
Read the original article Hit count: 910

Filed under:
|
|

Hello, is it possible to restart Tomcat6 by executing a JSP?

This because I would like to deploy the changes of an application by doing it remotely using the webserver.

The deploy script is written in bash and it checkouts the latest version from the svn, then package it as a war, then copy it in /webapps/ while adding some libs. If I execute it from a JSP (for example by using System.execute(..) will it cause problems?

The fact is that the script itself is something like:

/etc/init.d/tomcat6 stop
# do things
/etc/init.d/tomcat6 start

so I don't think it would work.. is there a way to execute a stand-alone process from inside tomcat?

© Stack Overflow or respective owner

Related posts about tomcat

Related posts about deploy