首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 移动开发 > 移动开发 >

ant起步和关闭tomcat

2012-09-14 
ant启动和关闭tomcat1.ant 直接启动tomcat,build.xml配置1.1启动tomcat注意tomcat.home是你的tomcat的安装

ant启动和关闭tomcat
1.ant 直接启动tomcat,build.xml配置1.1启动tomcat

注意tomcat.home是你的tomcat的安装路径

<target name="start-tomcat" description="tomcat starting.....">        <exec executable="${tomcat.home}/bin/startup.bat" spawn="true" vmlauncher="false">        <env key="CATALINA_HOME" value="${tomcat.home}" />        <arg line="/c start ${tomcat.home}/bin/startup.bat" />      </exec>   </target>
??1.2关闭tomcat
<target name="tomcat.stop"><java jar="${tomcat.home}/bin/bootstrap.jar" fork="true"><jvmarg value="-Dcatalina.home=${tomcat.home}"/><arg line="stop"/></java><waitfor maxwait="5" maxwaitunit="second">        <available file="errors.log"/></waitfor></target>
?

热点排行