|Summary:||do not override _RUNJAVA and _RUNJDB environment variables if already defined|
|Product:||Tomcat 6||Reporter:||Neeme Praks <neeme.praks>|
|Component:||Catalina||Assignee:||Tomcat Developers Mailing List <dev>|
Description Neeme Praks 2014-08-08 11:45:10 UTC
Created attachment 31888 [details] patch I'm integrating LiveRebel (http://liverebel.com) with Tomcat. I need a clean way how to get Tomcat scripts to start LiveRebel agent instead of Tomcat (the agent will be responsible for starting Tomcat). Currently we are patching Tomcat scripts (catalina.sh/bat and setclasspath.sh/bat); however, that is messy, as every time user updates Tomcat, those changes get overwritten. Instead, I would like to change the "java" executable that Tomcat scripts use to start Tomcat. My current solution is to set _RUNJAVA environment variable in CATALINA_BASE/bin/setenv.sh/bat and then patch CATALINA_HOME/bin/setclasspath.sh/bat not to override the setting if already set (see the attached patch). This solution is also described here: http://zeroturnaround.com/forums/topic/trouble-setting-up-live-rebel-with-tomcat-on-ubuntu/#post-45253
Comment 1 Mark Thomas 2014-08-11 21:35:21 UTC
Fixed in 8.0.x for 8.0.11 onwards and in 7.0.x for 7.0.56 onwards. I modified the patch slightly so setclasspath.sh handled java and jdb separately. The modified patch has been proposed for 6.0.x.
Comment 2 Mark Thomas 2014-09-30 13:32:32 UTC
This has been fixed in 6.0.x for 6.0.42 onwards.