After months of discussion on the virtues of cloud servers and Nginx, I was recently tasked with moving all the Nooku sites over to Rackspace Cloud. With that in mind, I have documented the basic install process for the benefit of all.

For our install, we will be using Ubuntu 10.04 and installing/configuring:

  • PHP 5.3.x (using fpm-php which is included)
  • MySQL 5.x
  • Nginx 8.x
In this tutorial I will take you through the install and the outline how I have set things up to gain maximum performance.

Recently I have been working on the demo server that will house our various demo sites.

One of the common issues with a demo site is that to preserve its integrity you may need to either restrict access or have a periodic rebuild. Restricting access may work sometimes but it’s likely to inhibit people trying out anything that is administrative in nature. Hence rebuilding the site is a far more appealing alternative.

The idea is basically delete everything and replace with a fresh copy, but to do so with minimum downtime. The result should be  a quick and secure rebuild. With that in mind we set about creating bash script that would rebuild the site as often as required (run as a cron job).

To get started I mapped out the process.

Site rebuilt workflow

As you can see we do everything using version control which in this case happened to be subversion.

By updating then exporting into a temp folder, the longest part of the process is done prior to any impact on the site. I threw in the checkout logic so that the same script could be used to build a brand new site (as in, one that does not already exist).

The first impact on the public site is the dropping of the database unless there have been changes to the repository that required database modifications.

For a typical site the whole process takes 13 seconds when no changes have been committed to subversion, with less than 2 seconds of downtime.
… continue reading …


Harbour with SplitView

Split View showing the boats list in Harbour, our example component

A month ago Martin asked a very interesting question on Twitter.

Possible to load a detail view & it’s related list view besides each other in the tab of a third view with the “H” of HMVC?

Short answer, yes offcourse ! Luckily our blog doesn’t have a 140 char limit so I can also show you how. In this tutorial I will explain:

  1. How to create a Ajaxed Split View.
  2. How to render that Split View from a module.

We will use the overlays we learned about in my previous blog post, and apply this to create the Split View.
… continue reading …