下载tomcat
http://tomcat.apache.org/index.html
修改$TOMCAT_HOME/conf/server.xml
<Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true"> <Context path="/" docBase="/sctu_vote" reloadable="true" /> </Host>
修改$TOMCAT_HOME/conf/tomcat-users.xml
<role rolename="tomcat"/> <role rolename="manager-gui"/> <user username="tomcat" password="tomcat" roles="tomcat,manager-gui"/>
启动tomcat
$TOMCAT_HOME/bin/catalina.sh start $TOMCAT_HOME/bin/catalina.sh stop
部署war包
查看日志
$TOMCAT_HOME/logs/catalina.out $TOMCAT_HOME/logs/localhost.2015-05-16.log