Dr Nic

Installing Mingle with Capistrano/Deprec

The other day I visited the ThoughtWorks office in Melbourne (they hosted the Melb Ruby meeting). The most notable feature of their office versus any office I’ve ever worked in before were the 5×3 cards (and post-it notes) … all over the walls.

From my understanding – which came after asking lots of questions – is that the cards help with:

  • The team (developers, clients, etc) deciding what parts of the application are most important to be built. The cards are isolated stories/use cases and should implicitly/explicitly state the business value. At each stage of the project – “iterations” which are 1 or 2 week long – the team decides which cards/stories should be implemented.
  • The cards for an iteration are placed on the wall. Thus it is transparent to all the team what work is being performed.
  • From left to right, the wall is divided into columns. Each card can be placed in one column. Columns are typically labelled with stage names like “Under development”, “Completed”, “QA/Testing”, “Accepted”. This gives a visualisation of what work/card is where in the development/release process. It can also indicate if there is a bottleneck – a lot of cards in the “QA/Testing” column might mean you need more testers.

The first point – using stories on cards to decide what should be built now – seemed like a winning idea. A new client of mine has trouble translating a gazillion feature requests into a sequence of “this part should be built now” stages. Everything is uber cricital, all the time. And often the feature requests don’t seem related to something a user might actually want to use.

Whilst cards on a wall would work if the client and developers were co-located (aka “sitting together”), that’s not the situation here. I’m in Brisbane, and they are in Sydney (1000km).

With colourful 5×3 cards and the promise of fruitful client relationships burned into my retina I wondered what web tools might help with emulating this process. The cards. The wall. The transparency. The understanding that “software costs money to build so what is most important?”

And I remembered Mingle – a tool built by ThoughtWorks for agile project development, but not (to my knowledge) used by any ThoughtWorks teams themselves. UPDATE: Jay Fields says several teams are currently using it.

But I can understand why they don’t use it. They have their own 5×3 cards with their “ThoughtWorks” logo on it. Well, they had some. I stole a bunch. They also have walls and co-location.

Nonetheless, I gave it a burl. I runs nicely when the server is installed on my CoreDuo 2gig MacBook. It didn’t run nicely at all on my 256Mb VPS that was already busy running a bunch of other things (mongrels, mysql, etc).

Mingle requires 2 gig of RAM. Even on the ever affordable Slicehost, that’s $140 USD a month. Mingle might be free for < 5 users (and OSS projects) but there is a notable hardware requirement, thanks I guess to the Java/JRuby/Rails stack.

But I've done something useful - I've written capistrano/deprec recipies to install Mingle on a remote machine with (minimal) manual intervention. You just need to choose a machine with 2G RAM spare. You also need Java and MySQL installed, but there are capistrano tasks to help with that too.

Ahh, the world of remote automation.

The recipe below is mostly *nix agnostic, except the java_install task which uses ubuntu/debian's apt-get system. Actually, it tells you what to manually run yourself, as Sun are tools and require you to "click" the word "Yes" twice. I don't know how to automate this with Capistrano.

The mingle_install task downloads and installs Mingle, and includes an JVM optimisation option that I found on the forums (the MingleServer.vmoptions file created).

So, from scratch, if you want to install Mingle on a remote server (independently of any Rails app etc), do the following:

sudo gem install deprec -v 1.9.1
alias cap1='cap _1.4.1_'
mkdir -p mingle_installer/config
cd !$
vim deploy.rb

And insert the following into the deploy.rb script.

Modify YOURDOMAIN to an IP that you have root access to. The script will create two folders - /usr/local/src/mingle and /var/www/apps/mingle. Its pretty harmless.

To install, run the capistrano tasks:

cd ..
cap1 java_install
cap1 mingle_install
cap1 mingle_start

BUT, mingle_start doesn't work. The server just doesn't start and I don't know why.

So, ssh into your machine (you had to do this for the java install step too BTW), and run:

/usr/local/src/mingle/MingleServer start

If we can fix this then that'd be uber cool.