'How to deploy Web Application in Tomcat7 using Eclipse Indigo?
Can any one tell how would I deploy my Web Application in Tomcat7 using Eclipse Indigo. When I manually create WAR and paste it in WebApps/ROOT then it works. But inEclipse IDE, server started successfully but not able to deploy war/web application. I also added myWeb Application using Add/Remove Server properties but all in vain. Only Apache server startUp page shown. Also when I double click Server My Server Locations tab is disabled. I don't know WHY ?
Secondly by default apache server access any jsp direct from WEBAPPS/abc.jsp or WEBAPPS/ROOT/abc.jsp?
Solution 1:[1]
It seems that your tomcat/web.xml is not properly configured. Follow this steps to get it work -
- First deleted server from servers tab in eclipse.
- Then add new server from wizard - which will ask you to give path of your tomcat installation directory usually in -
C:\Program Files\Apache Software Foundation - While last step, you will prompt an dialog box listing all the open projects of eclipse, to be add in tomcat environment.
- Click finish and clean/build project.
- check in web.xml that, your welcome file is properly added.(usually under WebContent directory )
Hope this will work for you.
Also note that, While developing any application, you don't need to create WAR.
Solution 2:[2]
You right click on tomcat icon in server tab then click on properties. In general click on "Switch Location" button then apply and ok. Now double click on Tomcat icon and see your Server Location is now enable. Then click on second radio button and save. Then try again to deploy. It should work.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Ved |
| Solution 2 | someone |
