Dan*_*son 6 reverse-proxy apache-2.2
我在 FreeBSD 上运行 Apache 2.2。最近我一直在为一些 Django/Python 寻找切诺基 + uWSGI。
我想将 Apache 2.2 保留在前面(端口 80 回复)并代理连接到在同一台机器上运行的切诺基服务器。
我的问题是我的 URL 上的几个目录位置有一些遗留的东西。
我想 / 去我的 Cherokee(反向代理),但为 /dir1/ 和 /dir2/ 保留 Apache。
我让反向代理与 mod_proxy 一起工作正常。
ProxyRequests Off
<Location />
ProxyPass http://127.0.0.1:8080/
ProxyPassReverse http://127.0.0.1:8080/
</Location>
Run Code Online (Sandbox Code Playgroud)
Cherokee 在本地主机的 8080 端口上运行。
问题是我不知道如何关闭 /dir1/ 和 /dir2/ 的反向代理,以便 Apache 处理对 dirs 的传入请求。
是否可以为 /dir1/ 和 /dir2/ 添加 Location 指令以告诉 Apache 不要反向代理目录?
从阅读ProxyPass
的文档中,你应该做这样的事情:
ProxyPass /dir1/ !
ProxyPass /dir2/ !
ProxyPass / http://127.0.0.1:8080/
ProxyPassReverse / http://127.0.0.1:8080/
Run Code Online (Sandbox Code Playgroud)