Setting up Trac, SVN and Agilo on RHEL 5.x

As part of yet another transformational project I am about to start from the very scratch. This time right from setting up the agile project management tools. I decided to go with trac (running agilo on top of it) for the agile delivery, svn for code versioning. This combination works very well together because:

  • You can have your product backlog, sprint backlog and tasks all in one place
  • Agilo manage your backlogs and provide fancy metrics of how your sprint is doing
  • SVN ties well into trac which means you can tie commits back into sprint tasks, which means you have a traceability matrix of the tasks/defects and the code changes made to close it
  • Trac also helps you manage a milestone so you can have a high-level view of how you are doing against your deadlines to meet a milestone

You can read more about them here Agilo and Trac

You first need to enable repoforge for your RHEL install and then install the required packages

[root@localhost ~]# rpm -Uhv http://apt.sw.be/redhat/el5/en/x86_64/rpmforge/RPMS//rpmforge-release-0.3.6-1.el5.rf.x86_64.rpm
[root@localhost ~]# yum -y install subversion trac mod_dav_svn mod_python

Now you need to create the directories for svn repos, trac project and auth directory. I choose /var/www/ but you can choose anything else you want.

[root@localhost ~]# mkdir -p /var/www/svn/svnrepos #holds the svn repos
[root@localhost ~]# mkdir -p /var/www/trac #trac base folder
[root@localhost ~]# mkdir -p /var/www/svn/auth #holds the htaccess files
[root@localhost ~]# htpasswd -c /var/www/svn/auth/svn.htpasswd svnuser
[root@localhost ~]# svnadmin create /var/www/svn/svnrepos/secret-project #create svn repo

Now create the initial svn folders/files in the repo

[root@localhost ~]# svn mkdir file:///var/www/svn/svnrepos/secret-project/branches  \
file:///var/www/svn/svnrepos/secret-project/tags  \
file:///var/www/svn/svnrepos/secret-project/trunk  \
-m 'creating directories for initial import'

Committed revision 1.

Now create your first trac project

[root@localhost ~]# trac-admin /var/www/trac/secret-project \
permission add tracuser TRAC_ADMIN

You will need then require to go the settings of trac to give it the svn repo patch and then using trac-admin to call resync.

[root@localhost ~]# trac-admin $ENV repository resync "secret-project"

You would also require a post commit hook to ensure that trac gets updated every time a new commit is made. There is plenty of information available on http://trac.edgewall.org/wiki/CommitTicketUpdater, but basically you need is an svn post commit hook which calls trac-admin $ENV changeset added 'secret-project'.

Installing Agilo can be done using a plugin. If you have easy_install installed even better. Just follow the instructions as follows

[root@localhost ~]# easy_install <agilo>.egg
[root@localhost ~]# cd /var/www/trac/britebill-holepunch/conf
[root@localhost conf]# trac-admin /var/www/trac/secret-project/ upgrade #upgrade trac post plugin install
Creating Product Backlog...
Creating Sprint Backlog...
Upgrade done.
[root@localhost conf]# trac-admin /var/www/trac/britebill-holepunch/ wiki upgrade #upgrade trac wiki as well

Now you can use the web interface to configure the project even more, adding your backlogs, tickets etc. Agilo also allows you to import your backlog from an xls sheet which is great as most product managers are still stuck in the xls era and refuse to let it go.

Tags: , , ,

About rp

Architect for large, highly scalable LAMP applications and Technical Manager with special focus on metrics based continuous improvement of teams and products. Rajat has close to a decade of experience of a very wide range of skills related to infrastructure, middleware, app servers all the way to front-end technologies and software development methodologies including agile, iterative waterfall, waterfall as well as ah-hoc startup using the right approach in the right context to reduce time to market.