如何在Tomcat 7中部署war文件 [英] How to deploy a war file in Tomcat 7
问题描述
我已将 sample.war
文件复制到Tomcat的 webapps
目录中,我可以访问 localhost:8080
。
I have copied the sample.war
file into the webapps
directory of Tomcat, and I can access localhost:8080
.
现在Tomcat如何部署它,我的意思是我需要在浏览器中打开它吗?如何访问应用程序?
Now how will Tomcat deploy it, I mean do I need to open it in browser? How can I access the application?
推荐答案
您可以从以下位置访问您的应用程序: http:// localhost :8080 / sample
You can access your application from: http://localhost:8080/sample
默认情况下,部署或重新部署war文件是自动的 - 复制/覆盖文件后示例.war
,检查解压缩文件夹的 webapps
文件夹示例
。
Deploying or redeploying of war files is automatic by default - after copying/overwriting the file sample.war
, check your webapps
folder for an extracted folder sample
.
如果无法正常打开,请检查日志文件(例如tomcat / logs / catalina.out)是否存在部署问题。
If it doesn't open properly, check the log files (e.g. tomcat/logs/catalina.out) for problems with deployment.
这篇关于如何在Tomcat 7中部署war文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!