引用
ProxyPassMatch Directive
Description: Maps remote servers into the local server URL-space using regular expressions
Syntax: ProxyPassMatch [regex] !|url [key=value [key=value ...]]
Context: server config, virtual host, directory
Status: Extension
Module: mod_proxy
Compatibility: available in Apache 2.2.5 and later
Description: Maps remote servers into the local server URL-space using regular expressions
Syntax: ProxyPassMatch [regex] !|url [key=value [key=value ...]]
Context: server config, virtual host, directory
Status: Extension
Module: mod_proxy
Compatibility: available in Apache 2.2.5 and later
比如,把asp的请求放到8080端口的服务器
<VirtualHost *:80>
ServerAdmin webmaster@aslibra.com
DocumentRoot "E:/webapps/www.aslibra.com"
ServerName www.aslibra.com
ErrorLog "logs/test.localhost-error.log"
CustomLog "logs/test.localhost-access.log" common
ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPassMatch .*\.asp http://127.0.0.1:8080/
ProxyPassReverse / http://127.0.0.1:8080/
</VirtualHost>
ServerAdmin webmaster@aslibra.com
DocumentRoot "E:/webapps/www.aslibra.com"
ServerName www.aslibra.com
ErrorLog "logs/test.localhost-error.log"
CustomLog "logs/test.localhost-access.log" common
ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPassMatch .*\.asp http://127.0.0.1:8080/
ProxyPassReverse / http://127.0.0.1:8080/
</VirtualHost>
这个会对给proxy带来很大的灵活性,参考官方介绍:
http://httpd.apache.org/docs/current/mod/mod_proxy.html
原创内容如转载请注明:来自 阿权的书房
收藏本文到网摘
android的apk文件的xml提取
转:什么样的女孩会有好的归宿
