Deploying my application at the root in Tomcat

后端 未结 10 1931
说谎
说谎 2020-11-22 06:25

I have the war file of my application. I need to deploy this at the root level. The current URL is http://localhost:8080/war_name/application_name.

10条回答
  •  醉梦人生
    2020-11-22 07:10

    on tomcat v.7 (vanilla installation)

    in your conf/server.xml add the following bit towards the end of the file, just before the closing tag:

    
        
        WEB-INF/web.xml
    
    

    Note that docBase attribute. It's the important bit. You either make sure you've deployed app_name before you change your root web app, or just copy your unpacked webapp (app_name) into your tomcat's webapps folder. Startup, visit root, see your app_name there!

提交回复
热议问题