apache 请求转发+去掉WWW和301重定向

Options +FollowSymLinks 

RewriteEngine on

RewriteCond %{HTTP_HOST} ^www.***.com

RewriteRule ^(.*)/index.html$ http://www.***.com/jr [L,R=301] 

RewriteRule ^(.*)/index.jsp$ http://www.***.com/jr [L,R=301] 

RewriteRule ^(.*)/index.action$ http://www.***.com/jr [L,R=301] 

 

 

RewriteCond %{HTTP_HOST} ^***.com

RewriteRule ^(.*)$ http://www.***.com$1 [L,R=301]

 

 

 

 

 

ProxyRequests Off

ProxyPass / balancer://jrserver/  

ProxyPassReverse / balancer://jrserver/

 

<Proxy balancer://jrserver>

BalancerMember http://www.***.com:8080/

</Proxy>

 

你可能感兴趣的:(apache)