Book Image

Redmine Cookbook

By : Shamasis Bhattacharya
Book Image

Redmine Cookbook

By: Shamasis Bhattacharya

Overview of this book

In a variety of online project management tools, Redmine markets itself as offering flexibility. Choosing the right management tool can mean the difference between the success and failure of a project. Flexible project management tools bend themselves to fit your needs, whether that’s communication regarding a simple project, or collaboration, or more complex project methodology such as SCRUM, or an issue-code relationship, or the need of different methodology for your project. Whether you are project manager or system administrator, this book provides valuable recipes to get the best possible performance out of your team, organization, infrastructure, and Redmine itself. Through a series of carefully crafted recipes covering the nitty-gritty of Redmine, you’ll be guided through the installation of Redmine, as well as how to fine-tune and customize your Redmine installation. Finally, we walk you through integrating Redmine with other softwares and databases like Tortoise SVN and Visual Studio and troubleshooting Redmine.
Table of Contents (17 chapters)
Redmine Cookbook
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

Default installation on an Ubuntu server


At the time of writing this book, the actual Ubuntu server version is 14.04 Long Term Support (LTS). So, this recipe covers installation on 14.04.3; however, things are probably not going to change much in the next few releases, and this is applicable to older versions of Ubuntu as well.

Getting ready

Make sure that you have sudo or root access to the server. If you don't have them, you may want to jump to Installing from a source on Ubuntu recipe, which explains how to install and run Redmine from the user's home directory.

  1. First of all, make sure that your system is up-to-date by running the following commands:

    sudo apt-get update && sudo apt-get upgrade
    
  2. Then, we need some prerequisites, such as MySQL or PostgreSQL, for the database. This recipe uses MySQL:

    sudo apt-get install mysql-server mysql-client
    
  3. During installation of MySQL you will be asked to enter a password for the MySQL root user. Write down this password, you are going to use it later.

How to do it…

After updating your system, go ahead and try a simple install:

sudo apt-get install redmine-mysql redmine

After running this command on a blank Linux server box, you may get a large number of dependencies to install. Just click <Yes> or press ENTER.

This process is going to take some time depending on your server and network capacity. The next screen that you get asks you to configure Redmine automatically; choose <Yes>.

If prompted for database configuration, choose MySQL. On the next several screens, provide the administration password that you wrote down and the database name for your Redmine installation; then, your username and password follows, which are used by Redmine.

After providing these credentials (which you should write down somewhere safe) and waiting for the apt-get script to finish, you 'll find your Redmine installed in the following folder:

/usr/share/redmine

To find out which version you installed, run the following:

more /usr/share/redmine/lib/redmine/version.rb

You will get something like this:

Your exact version is either Major, Minor, or Tiny, and in this case, it is Redmine 2.4.2 (shipped with Ubuntu 14.04.3). You will notice that the same version is used for Ubuntu versions. This rule applies for most open-software projects nowadays.

Accessing your Redmine

Installing Redmine on an Ubuntu system was easy and straightforward; however, accessing it via HTTP is not that easy and straightforward a task, and it gives you many options, as provided later in other recipes that deal with running Redmine on dedicated web server software.

To test the installation, perform the following:

  1. Navigate to the Redmine installation directory:

    cd /usr/share/redmine
    
  2. Run the WEBrick server to test the installation:

    sudo ruby script/rails server webrick –e production
    

WEBrick can be used in production, but it is highly recommended that you read other recipes in this chapter and choose a more advanced and reliable solution, such as Apache or Nginx, to run Redmine.

How it works…

Apt-get installations are supposed to help administrators save time on common administration tasks. Aptitude is a Linux package manager that comes shipped with Ubuntu and Ubuntu-like systems; it downloads precompiled binaries and runs configuration scripts. In this case, first we update and upgrade our Ubuntu system, then we install MySQL and Redmine. Aptitude automatically installs the required dependencies and configures the system for us.

Note

Please keep in mind that while this may be Ubuntu's default and easy installation way, it installs Redmine to be run as a root user, and running web-applications exposed to the Internet as the root user is not a good idea. This is because as time goes by, hackers might become aware of security holes and use them to hack your entire server.

There's more…

If you want to install a newer version of Redmine than the default one that is provided in the official Ubuntu channels or you want to update an existing one, you will want to add the following repository to your system. To add it, run the following:

sudo add-apt-repository ppa:ondrej/redmine
sudo apt-get update && sudo apt-get upgrade

You must run this step first. However, the ondrej/redmine repository does not always keep track of the latest Redmine releases. If you want to have the latest release and easily update it, read the next recipe.

See also

For more information on WEBrick server take a look at its documentation at http://ruby-doc.org/stdlib-2.0.0/libdoc/webrick/rdoc/WEBrick.html.