Tomcat - Multiple webapps folders

2019-04-08 11:53发布

Is it possible to have multiple folders where I can place applications to be deployed?

How are these defined?

And is it possible to restrict one folder to just be applications for "domain.com" and no other domain.

Thanks

1条回答
等我变得足够好
2楼-- · 2019-04-08 12:44

Take a look at conf/server.xml:

  <Host name="localhost" debug="0" appBase="webapps"
   unpackWARs="true" autoDeploy="true"
   xmlValidation="false" xmlNamespaceAware="false">

You can nest <Host> elements within the <Engine> element and have different ones corresponding to different virtual hosts, different appBase's etc.

Here's the documentation on the <Host> element.

查看更多
登录 后发表回答