Skip to main content

Running Plone behind an apache server

Alhamdullillah.. After a whole night of googling and hacking configurations I was finally able to configure Plone to run behind an apache server. I began my quest by googling and finding this page: . I don't need the ssl mentioned there but I did want to run Plone behind apache. But following the instructions didn't get me any result. So I tried to find out what on earth does the RewriteRule is actually about. After much googling again I found this: which also led me to an interesting albeit not really what I'm looking for now at Sooooo... the [P] actually stands for proxy.

Ok.. so now I'm getting somewhere. After much trial and error I finally figured out that I need to run:
sudo a2enmod proxy
sudo a2enmod proxy_http

To enable the proxy function in my apache server. Once that is done, it seems the rules given at the first website is not really correct. So in the end my .htaccess contains the following:
<IfModule mod_proxy.c>
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^(.*)$ http://localhost:8080/$1 [P]

But even though that is all fine and dandy, it didn't allow me to surf to more than the front page. All the subsequent links in the page was broken. And I experimented some more until finally I've got it at:

RewriteRule ^(.*) http://localhost:8080/VirtualHostBase/http/$1 [P]

Read the first article and it will mention about enabling Virtual Host Monster in the zope management page. But it did not mention about if you we're actually serving from a directory under your web root. Well, good thing the about page on the zope management page explained it all. So for the example above, my server was serving plone from the directory plone. The _vh_ tells the virtual host monster to append plone/ to every link it generates. Cool stuff..

So then I finally got it working. Alhamdullillah... Took a whole night. But seems to be very worth it.

Update (16 March 2008): Finally I've even got the layout working. After referring to and the Velo site it point to and also which explains what RewriteMap actually does. The RewriteMap part has to be part of the http.conf or if you are using Ubuntu in the sites configuration file. Then escape the request just like it says in the matthewwhitworth site and it all should work. Finally.


Anonymous said…
what a coincidence, I'm having almost the same problem just by a day later ;)
abdza said…
I still haven't gotten it running fully actually. The default layout seems
to be broken. When I try installing NuPlone it works but I like the default
layout better. Hope to find a solution soon.
Anonymous said…
try rewrite witch at
abdza said…
Thank you kedai for the tip. But I still can't seem to get it working. I'm not sure where is the problem but the layout is still completely way off. Try to look at I t seems the css doesn't load at all. And even adding new content it doesn't show up which might point to some problem with apache caching the thing. But I've actually even tried keying in the generated url ( by hand but it still doesn't display properly although the content is the latest one which might point to the fact that it doesn't go through any apache caching. Have to try it out some more.

Popular posts from this blog

Food first post

My blogs' name is High-Tech Rojak but I don't recall ever talking about food. So here's a first. Just recently I got some free time and finally got to cook the pasta I've bought for ages. So here's an account of how it went down.. :) Okay. That's the thing I cooked. I have no idea what it's called. At first I was thinking of buying the ribbon ones, then my wife looked at the colorful spiral ones and said "why not get these? they're more colorful" and so we got them (yes, we know nothing about pasta.. :) So I boiled it, actually put some salt and oil into the water so that they won't stick, drained it and tadaaaaa, you'd get the above. I remember once I tried to cook macaroni and I didn't drain it after boiling it, it filled up the whole pot. LOL... Learned my lesson. Next up the sauce. Like I said we don't know anything about pasta so here's the ingredients we prepared. Yes ladies and gentleman. Instant pasta sauce all bottl

Documentation is a must... after this.

I've been thinking quite a bit about documentation and the 'cost' it involves. And when I say documentation, I mean documentation in general about anything. One obvious case with the industry I'm involved in is user documentation (a.k.a The Manual). Creating great features in software takes time and effort but if it is not documented then the user won't even know about it and finally it never gets used. But then while documenting it you just wish that you're working on the next cool thing rather than have to write this up. So finally you end up not doing the documentation or doing it rather badly. Same thing with this blog writing. I have been doing some pretty interesting things with my phone (rooting it and using cynogenmod and all), some pretty significant life changes (my grandmother passed away) and a lot of other things which I should probably like to remember better or reflect more on it but not documented (here or anywhere permanent) and it would probabl

The Future Of Gaming

I love playing computer games. It's what originally drove me to learn computer programming, I wanted to create my own games. Until now I still have very little success with that, but... I have learnt to program web applications quite well and earning my pay using those skills. And I love open source software. Ever since I started programming professionally, my main work OS has always been Linux (various distributions and all and currently on Arch Linux). I always install dual-boot because... hardware problems (some projectors and printers just couldn't be detected by Linux when I started out, that's mostly not a problem now) and mainly to play games (sure there was some open source games available, but apart from "Battle for Wesnoth" and "FreeCiv" I don't actually recall any games I've played extensively enough to be remembered). But recently the gaming scene in LinuxLand has improved tremendously, partly thanks to the Windows 8 app store like