反向代理:当接收到一个http请求后apache server代理进行转发到新的服务器上进行处理
例如:
当我访问:http://localhost/x时就会跳转到:http://127.0.0.1:8080/ 上
<VirtualHost *:80> DocumentRoot "D:/Java/jar" ServerName localhost ProxyRequests Off <Proxy *> Order deny,allow Allow from all </Proxy> ProxyPass /x http://127.0.0.1:8080/ ProxyPassReverse /x http://127.0.0.1:8080/ ErrorLog "logs/doc-error.log" CustomLog "logs/doc-access.log" common <Directory "D:/Java/jar"> Options Indexes FollowSymLinks Includes ExecCGI AllowOverride All Require all granted </Directory> </VirtualHost> #路径映射 <IfModule alias_module> Alias /doc D:/Java/jar </IfModule>