HowTo install Redmine on CentOS 5 » History » Version 2

Serafim J Fagundes, 2010-12-28 17:24
Correction of words

1 1 Serafim J Fagundes
h2. Assuming
2 1 Serafim J Fagundes
3 1 Serafim J Fagundes
* Apache is up and running
4 1 Serafim J Fagundes
* Apache has previously been used and works quite well 
5 1 Serafim J Fagundes
* MySQL is up and running
6 1 Serafim J Fagundes
* MySQL has previously been used and works quite well
7 1 Serafim J Fagundes
* Your are logged as root
8 1 Serafim J Fagundes
* The next steps are done successively without errors
9 1 Serafim J Fagundes
10 1 Serafim J Fagundes
h3. Get Ruby
11 1 Serafim J Fagundes
12 1 Serafim J Fagundes
bq. cd ~/Downloads  # YOUR FOLDER OF CHOICE
13 1 Serafim J Fagundes
ftp ftp.ruby-lang.org
14 1 Serafim J Fagundes
cd /pub/ruby
15 1 Serafim J Fagundes
get ruby-1.8.7.pXXX.tar.gz
16 1 Serafim J Fagundes
tar zxvf ruby-1.8.7.pXXX.tar.gz ruby-1.8.7.pXXX
17 1 Serafim J Fagundes
cd ruby-1.8.7.pXXX
18 1 Serafim J Fagundes
./configure
19 1 Serafim J Fagundes
make
20 1 Serafim J Fagundes
make install
21 1 Serafim J Fagundes
ruby -v
22 1 Serafim J Fagundes
which ruby
23 1 Serafim J Fagundes
cd ..
24 1 Serafim J Fagundes
25 1 Serafim J Fagundes
h3. Get Gems
26 1 Serafim J Fagundes
27 1 Serafim J Fagundes
bq. wget http://production.cf.rubygems.org/rubygems/rubygems-1.x.tgz
28 1 Serafim J Fagundes
tar zxvf rubygems-1.x.tgz rubygems-1.x
29 1 Serafim J Fagundes
cd rubygems-1.x
30 1 Serafim J Fagundes
ruby setup.rb
31 1 Serafim J Fagundes
gem -v
32 1 Serafim J Fagundes
which gem
33 1 Serafim J Fagundes
cd ..
34 1 Serafim J Fagundes
35 1 Serafim J Fagundes
h3. Install Passenger
36 1 Serafim J Fagundes
37 1 Serafim J Fagundes
bq. gem install passenger
38 1 Serafim J Fagundes
passenger-install-apache2-module
39 1 Serafim J Fagundes
40 1 Serafim J Fagundes
h3. Restart Apache
41 1 Serafim J Fagundes
42 1 Serafim J Fagundes
h3. Download Redmine
43 1 Serafim J Fagundes
44 1 Serafim J Fagundes
bq. wget http://rubyforge.org/frs/download.php/73692/redmine-1.x.tar.gz  # GET LATEST VERSION ON RUBYFORGE
45 1 Serafim J Fagundes
tar zxvf redmine-1.x.tar.gz redmine-1.x
46 1 Serafim J Fagundes
47 1 Serafim J Fagundes
h3. Copy the folder to its HTTP document root folder
48 1 Serafim J Fagundes
49 1 Serafim J Fagundes
cp redmine-1.x /var/www/redmine-1.x
50 1 Serafim J Fagundes
51 1 Serafim J Fagundes
h3. Configure Apache to host the documents
52 1 Serafim J Fagundes
53 1 Serafim J Fagundes
h3. Install Bundler
54 1 Serafim J Fagundes
55 1 Serafim J Fagundes
bq. gem install Bundler
56 1 Serafim J Fagundes
57 1 Serafim J Fagundes
h3. Add the Bundler Boot and preinitializer code
58 1 Serafim J Fagundes
59 1 Serafim J Fagundes
(For more info go to the "Bundler site":http://gembundler.com/ )  
60 1 Serafim J Fagundes
61 1 Serafim J Fagundes
h3. Create the Gemfile and register these gems in it
62 1 Serafim J Fagundes
63 1 Serafim J Fagundes
* "rake", "0.8.3"
64 1 Serafim J Fagundes
* "rack", "1.0.1"
65 1 Serafim J Fagundes
* "i18n", "0.3.7"
66 1 Serafim J Fagundes
* "rubytree", "0.5.2", :require => "tree"
67 1 Serafim J Fagundes
* "RedCloth", "~>4.2.3", :require => "redcloth" # for CodeRay
68 1 Serafim J Fagundes
* "mysql"
69 1 Serafim J Fagundes
70 1 Serafim J Fagundes
bq. bundle install
71 1 Serafim J Fagundes
72 1 Serafim J Fagundes
h3. Create the Redmine MySQL database
73 1 Serafim J Fagundes
74 1 Serafim J Fagundes
h3. Configure database.yml (rename database.yml.example)
75 1 Serafim J Fagundes
76 1 Serafim J Fagundes
h3. Set the production environment (optional)
77 1 Serafim J Fagundes
78 1 Serafim J Fagundes
Uncomment the following line:
79 1 Serafim J Fagundes
80 1 Serafim J Fagundes
bq. ENV['RAILS_ENV'] ||= 'production'
81 1 Serafim J Fagundes
82 1 Serafim J Fagundes
h3. Generate the session store
83 1 Serafim J Fagundes
84 1 Serafim J Fagundes
bq.  RAILS_ENV=production bundle exec rake generate_session_store
85 1 Serafim J Fagundes
86 1 Serafim J Fagundes
h3. Migrate the database models
87 1 Serafim J Fagundes
88 1 Serafim J Fagundes
bq. RAILS_ENV=production bundle exec rake db:migrate
89 1 Serafim J Fagundes
90 1 Serafim J Fagundes
h3. Load default data (optional)
91 1 Serafim J Fagundes
92 1 Serafim J Fagundes
bq. RAILS_ENV=production bundle exec rake redmine:load_default_data
93 1 Serafim J Fagundes
94 1 Serafim J Fagundes
Follow instructions.
95 1 Serafim J Fagundes
96 1 Serafim J Fagundes
h3. Rename dispatch CGI files
97 1 Serafim J Fagundes
98 1 Serafim J Fagundes
bq. mv dispatch.cgi.example dispatch.cgi
99 1 Serafim J Fagundes
mv dispatch.fcgi.example dispatch.fcgi
100 1 Serafim J Fagundes
mv dispatch.rb.example dispatch.rb
101 1 Serafim J Fagundes
102 1 Serafim J Fagundes
h3. Edit .htaccess file for CGI dispatch configuration
103 1 Serafim J Fagundes
104 1 Serafim J Fagundes
h3. Chown and Chmod files for read/write access for the Apache user
105 1 Serafim J Fagundes
106 1 Serafim J Fagundes
bq. cd ..
107 1 Serafim J Fagundes
chown -R apache:apache redmine-1.x
108 1 Serafim J Fagundes
chmod -R 755 redmine-1.x
109 1 Serafim J Fagundes
110 2 Serafim J Fagundes
h3. Redmine should be fully installed now and fully usable
111 1 Serafim J Fagundes
112 1 Serafim J Fagundes
Enjoy!