Setting Up a Staging Site for Blosxom
I use the Blosxom blog-engine here at GlitchNYC both for its simplicity and its flexibilty.
The core system is super-simple: just put a file in a directory (say for example ~/blog/politics/) and it will show up on your front page. Eventually, it will get pushed down the page by newer articles, but is still accessible by topic (in the example above, the article was in the politics directory - that also becomes its category online). You can also access old articles by month or year, going back through the archives using the calendar plugin which you can see on my site.
In the wake of the recent Movable Type price hikes, I'm glad to be using an open source system, and I love being able to tweak the innards of blosxom myself.
Recently, I was griping about the fact that I will often post an article filled with typos, broken links, and missing images, simply because I can't see the article until I make it live. It turns out that Blosxom is so simple I only had to make a few minor changes to set up a little staging site.
First, I copied blosxom.cgi to staging.cgi. Next, I copied my blog directory in its entirety to ~/stage
the -a (archive flag) is the same as -dpR, meaning dereference links, preserve timestamps, and recursively copy all subfolders.
Now, I just load staging.cgi in my web browser and voila! There's my site complete with the new article. The actual site is still unchanged, but I can see exactly how it will look when I copy the new file over to the ~/blog directory.
All my resources such as CSS files, images, and the rest remain in the main directory of the web-site, accessible by both the staging URL and the live, real site.
It's already proved useful, but I've also already proved that I'm capable of overlooking typos on the staging site and posting anyway! At least it's one more check before going straight up with the articles like I used to.




