Update: 26 Nov 2011: I’m informed that WebFaction now has built-in installers for Redmine.
Since this is something I have recently had to do, and found the documentation to be out of date, I though I would share this working solution with you all. This is based on Redmine 0.9.x, and thanks to Sean F from WebFaction support, these instructions are mostly his.
- Go to your WebFaction control panel and create a new MySQL database, making a note of the database name and password.
- Create a new Rails 2.3.5 application from your control panel, noting the name of the application.
- Create a new website to serve the rails application you just created. eg, redmine.domain.com.
- Login to your server using SSH.
- Go to your Rails application directory, eg ‘cd ~/webapps/_my_redmineapp’ replacing ‘my_redmine_app’ with the name of your actual Rails application.
Run the following commands:
export PATH=$PWD/bin:$PATH export GEM_HOME=$PWD/gems gem install mysql wget http://rubyforge.org/frs/download.php/69449/redmine-0.9.3.tar.gz tar zxf redmine-0.9.3.tar.gz ln -s redmine-0.9.3 redmine cd redmine cp config/database.yml.example config/database.yml
Edit the ‘production’ section of ‘config/database.yml’ to configure it to use the database you created in step 1. ‘database’ and ‘username’ should be the name of the database, and ‘password’ should be the database password.
Execute the following commands, again from your Redmine application directory. eg ‘cd ~/webapps/_my_redmineapp/redmine’.
RAILS_ENV=production rake config/initializers/session_store.rb RAILS_ENV=production rake db:migrate RAILS_ENV=production rake redmine:load_default_data cd ..
Edit ‘nginx/conf/nginx.conf’ to change the text ‘hello_world’ to ‘redmine’.
Restart nginx with the following command:
./bin/restart
You should now have a working Redmine install at the website you specified in step 3.
One last thing you will probably want to do is get a working email setup so that Redmine can email people. I used SMTP for this, the process is quite simple:
- Create a new mailbox to handle your Redmine email, making a note of the username and password.
Go to your Redmine application directory, eg ‘cd ~/webapps/_my_redmineapp/redmine’ and execute the following:
cp config/email.yml.example config/email.yml
Edit ‘config/email.yml’ as described here, you will want to edit the ‘production’ entry as follows, replacing the place-holders accordingly:
production: delivery_method: :async_smtp smtp_settings: address: smtp.webfaction.com port: 25 domain: your_domain_name authentication: :login user_name: "your_mailbox_user" password: "your_mailbox_password"
Restart nginx (see step 10 from above).
And that’s that. You should now have email working with your Redmine install.
comments powered by Disqus