tomcat虚拟目录映射网络共享目录

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

<Context path="/sound" docBase="\192.168.1.120sound" debug="0"/>

<Host>

项目中录音文件存放在IP地址为192.168.1.120的服务器上,把sound文件夹设为共享,在tomcat server.xml中配置中加上上面的内容。

映射到子项目,配置:

<Context path="/" docBase="daixiui" debug="0"/>

参考链接:http://blog.csdn.net/lee4755026/article/details/7941765

原文地址:https://www.cnblogs.com/sshoub/p/6165317.html