ubuntu12.04安裝redmine
安裝mysql
<pre>
sudo apt-get install mysql-server
</pre>
配置mysql
<pre>
CREATE DATABASE redmine CHARACTER SET utf8;
CREATE USER 'redmine'@'localhost' IDENTIFIED BY 'my_password';
GRANT ALL PRIVILEGES ON redmine.* TO 'redmine'@'localhost';
</pre>
下載Redmine 2.4.2代碼
<pre>
wget http://www.redmine.org/releases/redmine-2.4.2.tar.gz
tar zxvf redmine-2.4.2.tar.gz
</pre>
安裝ruby1.9.3
<pre>
sudo apt-get install ruby1.9.3
</pre>
配置數(shù)據(jù)庫(kù)
<pre>
cd config
cp database.yml.example database.yml
</pre>
編輯database.yml
<pre>
production:
adapter: mysql2
database: redmine
host: localhost
username: redmine
password: "your_pwd"
encoding: utf8
</pre>
redmine-2.4.2目錄下執(zhí)行命令安裝gem的依賴項(xiàng)
<pre>
gem install bundler
</pre>
安裝redmine依賴項(xiàng)
<pre>
sudo apt-get install mysql-client
sudo apt-get install libmysqlclient-dev
sudo gem install mysql2 -v '0.3.16'
sudo apt-get install libmagickcore-dev libmagickwand-dev
bundle install --without development test
</pre>
最后安裝
<pre>
rake generate_secret_token
RAILS_ENV=production rake db:migrate
RAILS_ENV=production rake redmine:load_default_data
mkdir -p tmp tmp/pdf public/plugin_assets
chown -R 777 files log tmp public/plugin_assets
chmod -R 755 files log tmp public/plugin_assets
</pre>
啟動(dòng)
<pre>
sudo ruby script/rails server webrick -e production > /dev/null 2>&1 &
</pre>
后記
- 在安裝redmine依賴項(xiàng)時(shí)候,我才知道為什么需要有docker這種東西
- 內(nèi)網(wǎng)mysql root的密碼是droidhang
- 如何遷移redmine數(shù)據(jù)
- 本文參考