Project

General

Profile

RedmineInstall » History » Version 14

Jean-Philippe Lang, 2008-06-15 12:03
permissions

1 1 Jean-Philippe Lang
h1. Installing Redmine
2
3
{{>TOC}}
4
5
h2. Requirements
6
7 12 Jean-Philippe Lang
    * Ruby on Rails 2.0.2
8 1 Jean-Philippe Lang
    * A database (see compatibility below)
9
10
Optional:
11
12
    * SVN binaries (>= 1.3), for repository browsing (must be available in your PATH)
13
    * RMagick (Gantt export to a png image)
14
15
Supported databases:
16
17 13 Jean-Philippe Lang
    * MySQL 4 or higher (recommended)
18
    * PostgreSQL 8 (not thoroughly tested with 8.3)
19
    * SQLite 3 (please read this: http://weblog.rubyonrails.org/2007/1/29/using-sqlite3-with-rails)
20 1 Jean-Philippe Lang
21
h2. Installation
22
23 8 Thomas Lecavelier
1. [[Download]] and extract the archive or [[CheckingoutRedmine|checkout]] Redmine.
24 1 Jean-Philippe Lang
25 6 Jean-Philippe Lang
2. Create an empty database named @redmine@ for example.
26
27
For MySQL:
28
29
  create database redmine character set utf8;
30 1 Jean-Philippe Lang
31 9 Jean-Philippe Lang
3. Copy @config/database.yml.example@ to @config/database.yml@ and edit this file in order to configure your database settings for "production" environment.
32 1 Jean-Philippe Lang
33 3 Jean-Philippe Lang
Example for a MySQL database:
34 1 Jean-Philippe Lang
35 14 Jean-Philippe Lang
<pre>
36
production:
37
  adapter: mysql
38
  database: redmine
39
  host: localhost
40
  username: bduser
41
  password: bdpasswd
42
</pre>
43 3 Jean-Philippe Lang
44
4. Create the database structure, by running the following command under the application root directory:
45
46 1 Jean-Philippe Lang
  rake db:migrate RAILS_ENV="production"
47
48
It will create tables and an administrator account.
49
50 3 Jean-Philippe Lang
5. Insert default configuration data in database, by running the following command:
51 1 Jean-Philippe Lang
52
  rake redmine:load_default_data RAILS_ENV="production"
53
54
This step is optional but *highly recommended*, as you can define your own configuration from scratch. It will load default roles, trackers, statuses, workflows and enumerations.
55
56 14 Jean-Philippe Lang
6. Setting up permissions
57 1 Jean-Philippe Lang
58 14 Jean-Philippe Lang
The user who runs Redmine must have write permission on the following subdirectories: @files@, @log@, @tmp@ (create the last one if not present).
59
60
Assuming you run Redmine with a @redmine@ user:
61
62
<pre>
63
mkdir tmp
64
sudo chown -R redmine:redmine files log tmp
65
sudo chmod -R 755 files log tmp
66
</pre>
67
68
7. Test the installation by running WEBrick web server:
69
70 1 Jean-Philippe Lang
  ruby script/server -e production
71
72
Once WEBrick has started, point your browser to http://localhost:3000/. You should now see the application welcome page.
73
74 14 Jean-Philippe Lang
8. Use default administrator account to log in:
75 1 Jean-Philippe Lang
76
    * login: admin
77
    * password: admin
78
79 14 Jean-Philippe Lang
You can go to @Admin & Settings@ to modify application settings.
80 1 Jean-Philippe Lang
81
h2. SMTP server Configuration
82
83
In config/environment.rb, you can set parameters for your SMTP server:
84
85
    * config.action_mailer.smtp_settings: SMTP server configuration
86
    * config.action_mailer.perform_deliveries: set to false to disable mail delivering
87
88 7 Thomas Lecavelier
Don't forget to restart the application after any change.
89 11 Jean-Philippe Lang
90
h2. Backups
91
92
Redmine backups should include:
93
* data (stored in your redmine database)
94
* attachments (stored in the @files@ directory of your Redmine install)
95
96
Here is a simple shell script that can be used for daily backups (assuming you're using a mysql database):
97
98
<pre>
99
# Database
100
/usr/bin/mysqldump -u <username> -p <password> <redmine_database> | gzip > /path/to/backup/db/redmine_`date +%y_%m_%d`.gz
101
102
# Attachments
103
rsync -a /path/to/redmine/files /path/to/backup/files
104
</pre>