redmine是一個開源的項(xiàng)目管理軟件,其主頁是:http://www.redmine.org
redmine是基于Ruby on Rails框架的,跨平臺和跨數(shù)據(jù)庫。
安裝過程
===========================
1. 到主頁下載redmine的源碼包并解壓
2. 根據(jù)redmine的版本,安裝對應(yīng)的ruby版本
3. 安裝數(shù)據(jù)庫:這里選擇mysql數(shù)據(jù)庫
4. 在數(shù)據(jù)庫中創(chuàng)建redmine所使用的用戶和庫
CREATE DATABASE redmine CHARACTER SET utf8;
CREATE USER 'redmine'@'localhost' IDENTIFIED BY 'my_password';
GRANT ALL PRIVILEGES ON redmine.* TO 'redmine'@'localhost';
5. 修改redmine數(shù)據(jù)庫連接配置
到redmine解壓目錄下的:cp config/database.yml.example config/database.yml
配置如下:
production:
adapter: mysql2
database: redmine
host: localhost
username: redmine
password: my_password
6. redmine依賴安裝
redmine使用Bundler管理gems依賴,所以首先安裝Bundler,執(zhí)行:
gem install bundler
然后安裝所有的gems依賴,執(zhí)行:
bundle install --without development test
7. 可選依賴RMagick (操作圖片),執(zhí)行:
bundle install --without development test rmagick
8. 生成session加密秘鑰
bundle exec rake generate_secret_token
9. 生成數(shù)據(jù)庫結(jié)構(gòu)
RAILS_ENV=production bundle exec rake db:migrate
10. 生成數(shù)據(jù)庫數(shù)據(jù)
RAILS_ENV=production bundle exec rake redmine:load_default_data
11. 文件目錄及權(quán)限(根據(jù)自己實(shí)際情況修改)
mkdir -p tmp tmp/pdf public/plugin_assets
sudo chown -R redmine:redmine files log tmp public/plugin_assets
sudo chmod -R 755 files log tmp public/plugin_assets
12. 啟動redmine
bundle exec rails server webrick -e production -b 0.0.0.0
13. 訪問:http://ip:3000
用戶:admin admin