2

How can I make sure that the server.xml which Eclipse produces for every separate project that relies on Tomcat, will always contain a specific option, which I added manually?

I'd like to add a bunch of <Context> mappings to the server.xml file. I tried doing that in the server.xml in the main tomcat dir - didn't work.

Then I saw that Eclipse builds a temporary folder for every project that uses Tomcat. This folder also containes this server.xml file. I edited it, and voila, it worked. However, soon after that the same file got updated by Eclipse, with the original data that it contained.

It is not very efficient to manually copy and paste the code every time before I run/restart tomcat. I hope there is a more permanent way.

Jay
  • 19,649
  • 38
  • 121
  • 184
xantrus
  • 1,975
  • 1
  • 22
  • 44

1 Answers1

4

Let's assume you have configured tomcat 5.5

If you have configured your tomcat server in eclipse using all default options, you want to edit the server.xml located at WORKSPACE_LOC\Servers\Tomcat v5.5 Server at localhost-config\server.xml

Amol Katdare
  • 6,740
  • 2
  • 33
  • 36