::You must have ninja focus to complete your mission::NinjaFocus::





Redmine is a Ruby on Rails application for project management and source code control. It offers a front end to version control software such as Subversion and Git. It also has a wiki for documentation and a ticketing system which can be used for planning and bug tracking.

If that wasn't enough, Redmine supports multiple projects, authentication and varying user rights across projects.

It's like Trac but with a few more features (e.g. multiple projects).

This guide covers installing Redmine on a CentOS 5.0 Server, there might be some subtle differences on other distros but nothing too complicated to figure out.



Following the instructions to prepare your server for Ruby on Rails (these also include the details you need to install Ruby and mod_fastcgi for Apache).

You may need to have a specific version of rails installed. At the time of writing this is 2.1.0. You can install it like this:

# gem install rails --version 2.1.0

If you want Redmine to make Gantt charts for you you'll need to install RMagick too:

# gem install rmagick

Basic Folder File Structure

You need to create an apache virtual host for the application, so for the sake of this documentation we are going to use the site "redmine.example.com" in the examples.

First off, you need to create a place to keep the application and any associated files for the apache virtual host.

# mkdir /var/www/vhosts/redmine.example.com
# cd /var/www/vhosts/redmine.example.com
# mkdir conf logs
# touch logs/access_log logs/error_log

Downloading Redmine

Now we've prepared these basic files, it's time to get Redmine on the server. Although it is possible to download a tarball from the redmine site, this will only mean you have to got back again when an update is released. Instead, you can get a copy of Redmine from their Subversion repository.

At this time, you need to have one of the more recent development versions of Redmine if you want to also use the latest releases of Ruby and Ruby on Rails. If you'd prefer to have only official releases, then you need to check on the Redmine web site to find the current release version number.

In any case, using subversion will allow you quickly pull updates to your server and let you switch between versions.

To check out the latest version from the Redmine repository, use the following command:

# cd /var/www/vhosts/redmine.example.com/
# svn co http://www.redmine.org/svn/trunk redmine

If you want to download an official release of Redmine, find out the version number then use the following command:

# cd /var/www/vhosts/redmine.example.com
# svn co http://www.redmine.org/svn/tags/<version number> redmine

So, if you wanted to install version 0.7.3 then you would use:

# svn co http://www.redmine.org/svn/tags/0.7.3 redmine

Apache Configuration

Next we need to create the basic apache configuration files for this virtual host. I keep all configuration files for each virtual host separate and in a folder called /etc/httpd/vhosts.d, every one has there preferred way to organise their files.

What you'll need to do is include the following after you default virtual host configuration directives.

<VirtualHost *:80>
        ServerName redmine.example.com
        DocumentRoot /var/www/vhosts/redmine.example.com/redmine/public

        # make sure passenger is enabled
        RailsBaseURI /

        CustomLog  /var/www/vhosts/redmine.example.com/logs/access_log combined
        ErrorLog  /var/www/vhosts/redmine.example.com/logs/error_log
        <Directory /var/www/vhosts/redmine.example.com/public>
                 # shouldn't hurt but best to make sure php can't run on the vhost
                <IfModule mod_php5.c>
                     php_admin_flag engine off
                Options Indexes FollowSymlinks
                Order allow,deny
                Allow from all

The Redmine folder structure contain a folder called "public" which we have made the document root for the virtual host. This folder contains a simple .htaccess file which carries out the mod_fastcgi and mod_rewrite configuration.

FIXME: AllowOverride rules need updating

MySQL Database and User Account

Main Menu

Personal tools