tomcat6的一些配置

一,tomcat Host的属性autoDeploy 为true自动部署的情况

注:unpackWARs="true"

Deployment of .WAR files copied into the Host appBase. 复制到server.xml 的 <Host标签 的 属性appBase指定的目录          的webapp Deployment of exploded web applications which are copied into the Host appBase. 复制到The Host appBase ,解压后的 webapp Re-deployment of a web application which has already been deployed from a .WAR when the new .WAR is provided. In this case the exploded web application is removed, and the .WAR is expanded again. Note that the explosion will not occur if the Host is configured so that .WARs are not exploded with a unpackWARs attribute set to "false", in which case the web application will be simply redeployed as a compressed archive. 重新部署*.war有更新的文件,旧的解压文件被删除,新的*.war文件重新解压部署的webapp。注意:如果 Host的unpackWARs属性设置为false将不被解压,只是作为压缩文档简单部署而已 Re-deployment of a web application if the /WEB-INF/web.xml file (or any other resource defined as a WatchedResource) is updated 重新部署/WEB-INF/web.xml有更新(或者其他被作为监视的资源被修改的情况) web app. Re-deployment of a web application if the Context Descriptor file from which the web application has been deployed is updated. 重新部署$CATALINA_BASE/conf/[engineName]/[Hostname]/directory.xml有更新的webapp Re-deployment of a web application if a Context Descriptor file (with a filename corresponding to the Context path of the previously deployed web application) is added to the $CATALINA_BASE/conf/[enginename]/[hostname]/ directory. 重新部署添加到 $CATALINA_BASE/conf/[enginename]/[hostname]/  directory.的webapp Undeployment of a web application if its document base (docBase) is deleted. Note that on Windows, this assumes that anti-locking features (see Context configuration) are enabled, otherwise it is not possible to delete the resources of a running web application 卸载Context属性docBase指定目录被删除的web app。注意在windows上,这只是一个假想,因为windows的锁功能,不可能删除一个正在运行的webapp

 

二,tomcat6多域名绑定

 

In many server environments, Network Administrators have configured more than one network name (in the Domain 

 

Name Service (DNS) server), that resolve to the IP address of the same server. Normally, each such network 

 

name would be configured as a separate Host element in conf/server.xml, each with its own set of web 

 

applications.

 

However, in some circumstances, it is desireable that two or more network names should resolve to the same 

 

virtual host, running the same set of applications. A common use case for this scenario is a corporate web 

 

site, where it is desireable that users be able to utilize either www.mycompany.com or company.com to access 

 

exactly the same content and applications.

 

This is accomplished by utilizing one or more Alias elements nested inside your Host element. For example:

 

 

 <Host name="www.mycompany.com" ...>

  ...

  <Alias>mycompany.com</Alias>

  ...

</Host>

 

 

 

 

In order for this strategy to be effective, all of the network names involved must be registered in your DNS 

 

server to resolve to the same computer that is running this in、

三,设置允许和禁用ip,domain

 

You can ask Catalina to check the IP address, or host name, on every incoming request directed to the surrounding Engine, Host, or Context element. The remote address or name will be checked against a configured list of "accept" and/or "deny" filters, which are defined using the Regular Expression syntax supported by the Jakarta Regexp regular expression library. Requests that come from locations that are not accepted will be rejected with an HTTP "Forbidden" error. Example filter declarations:

<Engine name="Standalone" ...>
  ...
  <Valve className="org.apache.catalina.valves.RemoteHostValve"
         allow="*.mycompany.com,www.yourcompany.com"/>
  <Valve className="org.apache.catalina.valves.RemoteAddrValve"
         deny="192.168.1.*"/>
  ...
</Engine>

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值