Wikipedia behind mod_proxy
The wikipedia software runs only on PHP 4 (due to bad class naming in PHPTAL), but I wanted to let the accompanying wiki to this blog to run under the same domain as the blog itself: mod_proxy to the rescue. The following lines in httpd.conf got things quite smoothly started (and you know now, how the reach the wiki with circumventing the proxy, but so what ;)):
ProxyPass /wiki/ http://blog4p.bitflux.ch/wiki/
ProxyPassReverse /wiki/ http://blog4p.bitflux.ch/wiki/
Until I got a complaint, that the wiki can't be edited anymore. This happened after I blocked a wiki-spammer by username (they are worse than comment spammers...), but since wikipedia also remembers the IP of the offending spammer (which - "thanks" to proxying - was the one of the blogserver), everyone else was also blocked... Not surprisingly, wikipedia took precautions for this scenario, just add the following to LocalSettings.php and wikipedia honors the X-Forwarded-For header added by mod_proxy:
$wgUseSquid = true;
I don't know, if it tries some proprietary squid stuff with just this setting (there are more Squid options available in LocalSettings.php), but it seems to work. Please report, if you still encounter problems.
Add a comment
Your email adress will never be published. Comment spam will be deleted!