Set up Redmine on DreamHost using Passenger and Apache

Redmine is described on its website as a “flexible project management web application. Written using the Ruby on Rails framework, it is cross-platform and cross-database.” It is also free and open source. I will show you how to install it using Passenger and Apache.

Prerequisite: Before you start this tutorial, check out one of my previous articles on setting up RVM for shared or VPS. Go through the steps outlined in the tutorial, but stop short of installing Rails.

Installing can be a bit trickey due to the rmagick gem. Current imagemagick libraries on DreamHost servers are a little out of date, so you need to perform some workarounds. This means installing a more recent version of imagemagick locally and creating a couple of paths in the .bash_profile.

Let’s start off by cd’ing into your root SSH user directory:

Now make a src directory in which we will download our tar ball source archive.

Now fetch a version of ImageMagick prior to 7.0. As of the time of this writing, there was a change in paths within 7.0 that will cause the current rmagick gem to not compile:

Make a lib directory in the users root directory into which we will install our compiled library files.

Decompress the tar.gz file.

Now we are going to cd into our source file directory and start the configure and compile process.

Take careful note of the prefix and the path noted. This will tell the compiler where we want our compiled binary to go to. Modify this to your local user path. This will take a minute or two. Once complete we run the make command.

This make process will take even longer. Once that is complete, we then install the compiled source to our directory we set up in the initial configure command.

Next we need to set some environment variables so rmagick can locate our local libraries. In the .bash_profile add the following:

Remember to replace the username with the one you are logged in with.

Source the .bash_profile file to reload the new settings:

Next cd into the domain directory where and download the latest redmine archive and decompress it.

Visit the MySQL admin page in the DreamHost panel at create a new database, user, and host name for the redmine install.

In the main app directory copy the db config example file.

Open up the file and edit the production settings with the information from the MySQL DreamHost panel.

Now we are ready to install bundler and run the bundle command using the supplied Gemfile.

All should go as planned since we installed and compiled a newer version of imagemagick and set the path variables in a previous step. If you are still having issues and wish to bypass rmagick, you can enter in the following:

Next we store the secret token in our DB using the following command:

If the MySQL information was entered correctly the preceding command will complete without any fatal errors. A couple of more steps to go:

One final rake command.


That is all that needs to be done to set up redmine on DreamHost. You should be able to visit the site in a browser and login with the default login details which are username: admin and password: admin.

Have a comment or a question? Feel free to post below.