Changeset 25321 for main/trunk/greenstone3/build.xml
- Timestamp:
- 2012-03-30T20:00:47+13:00 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone3/build.xml
r25314 r25321 1108 1108 <!-- windows: do we want to launch a webrowser?? --> 1109 1109 <!-- shouldn't this test whether anything is running first? --> 1110 <target name=" stop-tomcat" description="Shutdown only Tomcat" depends="init" if="tomcat.islocal">1110 <target name="force-stop-tomcat" description="Shutdown only Tomcat" depends="init" if="tomcat.islocal"> 1111 1111 <exec executable="${catalina.home}/bin/shutdown.sh" os="${os.unix}" dir="${catalina.home}/bin" spawn="false"> 1112 1112 <env key="CATALINA_HOME" value="${catalina.home}"/> … … 1116 1116 </exec> 1117 1117 </target> 1118 1119 <target name="check-tomcat-running"> 1120 <!--can also try the "socket" condition in place of the "http" condition--> 1121 <condition property="tomcat.isrunning"><!--<waitfor maxwait="5" maxwaitunit="second" timeoutproperty="tomcat.isstopped">--> 1122 <http url="http://${tomcat.server}:${tomcat.port}${app.path}"/> <!--host:port/greenstone3--> 1123 </condition><!--</waitfor>--> 1124 </target> 1125 1126 <target name="stop-tomcat" description="Shutdown only Tomcat if running" depends="check-tomcat-running" if="tomcat.isrunning"> 1127 <antcall target="force-stop-tomcat"/> 1128 </target> 1129 1118 1130 1119 1131 <target name="restart-tomcat" description="Shutdown and restart only Tomcat" depends="init,stop-tomcat,start-tomcat"/> … … 1223 1235 <handler classname="org.apache.tools.ant.input.SecureInputHandler" /> <!-- password won't be visible on screen --> 1224 1236 </input> 1225 <antcall target="stop-tomcat"/> 1237 1238 <!-- stop tomcat if running, since derby db is embedded and only allows connections from one jvm instance at a time 1239 See http://db.apache.org/derby/papers/DerbyTut/embedded_intro.html --> 1240 1241 <!--<antcall target="check-tomcat-running"/>--><!--won't set the tomcat.isrunning property for use below--> 1242 <condition property="tomcat.isrunning"> 1243 <http url="http://${tomcat.server}:${tomcat.port}${app.path}"/><!--can also try the "socket" condition in place of the "http" condition--> 1244 </condition> 1245 <if> 1246 <bool> 1247 <istrue value="${tomcat.isrunning}"/> 1248 </bool> 1249 <antcall target="force-stop-tomcat"/> 1250 </if> 1251 1226 1252 <!--<echo>${admin.password}</echo>--> <!-- for testing --> 1227 1253 <java classname="org.greenstone.gsdl3.util.ChangePwdUsersDB"> … … 1231 1257 <arg value="${admin.password}"/> 1232 1258 </java> 1233 <antcall target="start-tomcat"/> 1259 1260 <!-- run tomcat again if it used to be running --> 1261 <if> 1262 <bool> 1263 <istrue value="${tomcat.isrunning}"/> 1264 </bool> 1265 <antcall target="start-tomcat"/> 1266 </if> 1234 1267 </target> 1235 1268
Note:
See TracChangeset
for help on using the changeset viewer.