I'm trying to use mod_proxy_html on Ubuntu which I installed from apt-get. The module is loading properly and all ProxyHTML* directives work except for the one that matters the most. When I do "ProxyHTMLEnable on" in my apache2.conf or vhost conf files, apache complains that it's an invalid directive and I must have misspelled it. Is开发者_JAVA百科 anyone else having this issue on Ubuntu and what can be done to fix it?
Have you tried leaving out "ProxyHTMLEnable on" entirely? I think that directive is new and not in the version in Ubuntu.
Do put "SetOutputFilter proxy-html" in its place
While this isn't necessarily specific to the question, I figured I'd throw this out there for anyone else getting here from the Google super-highway.
I tried just removing the ProxyHTMLEnable On
and adding SetOuputFilter proxy-html
, but still wasn't working for me. The "gotcha" in my case was the content mod_proxy_html was trying to process was compressed.
Adding SetOutputFilter INFLATE;proxy-html;DEFLATE
instead of SetOuputFilter proxy-html
did it for me. (will obviously lead to more processing being done)
This site explains it much better than I can: http://wiki.uniformserver.com/index.php/Reverse_Proxy_Server_2:_mod_proxy_html_2#Cause_and_Solution_3
精彩评论