
Redmine是一个不错的项目管理工具,是用RUBY开发的基于WEB的项目管理软件,提供项目管理、WIKI、新闻台等功能,集成版本管理系统GIT、SVN、CVS等等。通过WEB 形式把成员、任务、文档、讨论以及各种形式的资源组织在一起,推动项目的进度。
以前在Window下安装过,现在在Linux上安装使用。
Window下可一键安装,参考本站一键安装Redmine
1.安装ruby环境,Redmine是基于Ruby on rails开发的
1 2 3 4 5 6 7 8 9
| \curl -L https: source /etc/profile.d/rvm.sh
rvm list known
rvm install 2.2
ruby -v
|
2.安装rails
1 2 3 4 5
| gem install rails
rails -v
|
3.下载redmine
官网 http://www.redmine.org/
1 2 3
| wget http:
tar zxvf redmine-2.6.0.tar.gz
|
4.依赖组件安装
1 2 3 4 5
| cd redmine-2.6.0
gem install bundler
bundle install --without development test rmagick
|
5.配置redmine连接数据库
1 2 3 4 5 6 7
|
cp config/database.yml.example config/database.yml
vi config/database.yml
|
6.创建一个session安装密钥
1
| rake generate_secret_token
|
7.生成初始化所有table
1
| RAILS_ENV=production rake db:migrate
|
8.装入默认的配置信息,输入zh(选择中文)
RAILS_ENV=production rake redmine:load_default_data
9.启动redmine
1 2 3 4 5 6
| ruby script/rails server webrick -e production
ruby bin/rails server webrick -e production
ruby bin/rails server webrick -e production -d
|
10.开机自动启动
1 2 3 4 5 6 7 8
|
vi /etc/rc.local
/usr/local/rvm/rubies/ruby-1.9.3-p551/bin/ruby /root/redmine-2.6.0/script/rails server webrick -e production -d
|
11.配置Nginx模块
1 2 3 4 5 6 7 8 9 10 11
| passenger-config --root
passenger-install-nginx-module
./configure --user=www --group=www --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_gzip_static_module --with-ipv6 --add-module=/usr/local/rvm/gems/ruby-2.2.6/gems/passenger-5.0.30/ext/nginx/
|
12.nginx配置upstream
upstream redmine {
server 127.0.0.1:3000;
}
server {
server_name wiki.pangxieke.com;
root /usr/local/redmine;
location / {
try_files $uri @ruby;
}
location @ruby {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_read_timeout 300;
proxy_pass http://redmine;
}
}
参考文献
http://www.redmine.org/projects/redmine/wiki/RedmineInstall
Redmine官网http://www.redmine.org/