HowTo Install Redmine 231 On Ubuntu 1204 with git and Redmine Git Hosting plugin » History » Version 5
Yovav Cohen Tene, 2013-07-13 21:01
1 | 1 | Yovav Cohen Tene | h1. HowTo Install Redmine 231 On Ubuntu 1204 clean installation with git and Redmine Git Hosting plugin |
---|---|---|---|
2 | |||
3 | h2. Installing LAMP |
||
4 | 2 | Yovav Cohen Tene | |
5 | 1 | Yovav Cohen Tene | <pre> |
6 | apt-get update && apt-get upgrade -y |
||
7 | reboot |
||
8 | apt-get install tasksel |
||
9 | 3 | Yovav Cohen Tene | tasksel |
10 | 1 | Yovav Cohen Tene | </pre> |
11 | |||
12 | 3 | Yovav Cohen Tene | choose LAMP server and choose a password for MySQL root account |
13 | |||
14 | h2. Installing Packages |
||
15 | |||
16 | <pre> |
||
17 | apt-get install ruby rubygems libruby libapache2-mod-passenger ruby-dev libmysqlclient-dev libmagickcore-dev libmagickwand-dev -y |
||
18 | </pre> |
||
19 | |||
20 | h2. Installing Redmine |
||
21 | |||
22 | <pre> |
||
23 | cd /tmp |
||
24 | wget rubyforge.org/frs/download.php/76933/redmine-2.3.1.tar.gz |
||
25 | tar -xzvf redmine-2.3.1.tar.gz |
||
26 | mv redmine-2.3.1 /usr/local/share/redmine-2.3.1 |
||
27 | ln -s /usr/local/share/redmine-2.3.1 /usr/local/share/redmine |
||
28 | chown -R root:root /usr/local/share/redmine-2.3.1 |
||
29 | 4 | Yovav Cohen Tene | gem install bundler |
30 | cd /usr/local/share/redmine/ |
||
31 | bundle install --without development test postgresql sqlite |
||
32 | </pre> |
||
33 | |||
34 | h2 .Setting up Redmine user and database in MySQL |
||
35 | |||
36 | <pre> |
||
37 | mysql -u root -p |
||
38 | </pre> |
||
39 | <pre> |
||
40 | CREATE DATABASE redmine CHARACTER SET utf8; |
||
41 | CREATE USER 'redmine'@'localhost' IDENTIFIED BY 'my_password'; |
||
42 | 1 | Yovav Cohen Tene | GRANT ALL PRIVILEGES ON redmine.* TO 'redmine'@'localhost'; |
43 | 5 | Yovav Cohen Tene | </pre> |
44 | |||
45 | h2. Configuration |
||
46 | |||
47 | Copy /usr/local/share/redmine/config/database.yml.example to /usr/local/share/redmine/config/database.yml and edit this file in order to configure your database settings for "production" environment. |
||
48 | Example for a MySQL database using ruby1.8 or jruby: |
||
49 | <pre> |
||
50 | production: |
||
51 | adapter: mysql2 (note: For Rails < 3.1 use mysql instead of mysql2) |
||
52 | database: redmine |
||
53 | host: localhost |
||
54 | username: redmine |
||
55 | password: my_password |
||
56 | </pre> |
||
57 | |||
58 | Generate a session store secret: |
||
59 | <pre> |
||
60 | rake generate_secret_token |
||
61 | </pre> |
||
62 | |||
63 | Generate the database structure: |
||
64 | <pre> |
||
65 | RAILS_ENV=production rake db:migrate |
||
66 | </pre> |
||
67 | |||
68 | Generate default configuration data: |
||
69 | <pre> |
||
70 | RAILS_ENV=production rake redmine:load_default_data |
||
71 | </pre> |
||
72 | (using “es” for Spanish language in terminal prompt) |
||
73 | |||
74 | h4. Database encryption |
||
75 | |||
76 | If you want to encrypt your redmine database do as follows: |
||
77 | |||
78 | # Copy the default config file @/usr/local/share/redmine/config/configuration.yml.example@ to @/usr/local/share/redmine/config/configuration.yml@ |
||
79 | # Edit configuration.yml and create a cipher key there for the environment you've used so thus far - production. Be sure to read the comment in this file. They are very detailed and there for you. |
||
80 | # Run: <pre> |
||
81 | rake db:encrypt RAILS_ENV=production |
||
82 | 3 | Yovav Cohen Tene | </pre> |