Redmine是用Ruby开发的基于web的项目管理软件,它提供了很多功能,但是我们平常用的最多的是Issues以及wiki功能模块。但是在使用过程中,我们发下redmine做项目管理有一些局限性:
1)虽然可以有效地管理Issues,但是对于短期的迭代任务非常不清晰,后来我们移到了Trello,用卡来管理短期迭代任务
2)不利于项目组中其他成员了解整个项目
3)Wiki对于资料的管理以及查询功能都非常弱,经常发现资料找不到的情况
4) Trello可以解决短期迭代小任务的管理也可以让项目组成员互相了解,但是QA团队不买账,因为他们的bug不好统计。
为了将 Redmine以及Trello更好地结合起来,发现Redmine2.6.1版本上可以安装Agile 插件来实现卡的管理,因此这就有了上述任务的由来。
一.环境准备(CentOS6.4)
安装 GCC
$sudo yum –y install gcc $sudo yum –y install pcre-devel openssl openssl-devel |
安装RVM并且验证RVM环境
$ curl -L https://get.rvm.io | bash -s stable $ source ~/.rvm/scripts/rvm $ rvm -v rvm 1.22.17 (stable) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/] |
安装Ruby
$rvm install 2.0.0 $rvm 2.0.0 --default $ ruby -v ruby 2.0.0p247 (2013-06-27 revision 41674) [x86_64-darwin13.0.0] $ gem -v 2.1.6 $ gem source -r https://rubygems.org/ $ gem source -a https://ruby.taobao.org |
安装Rails
sudo yum install –y libxml2 libxm2-devel sudo yum -y install libxslt libxslt-devel gem install nokogiri -- --use-system-libraries --with-xml2-lib=/usr/lib64 --with-xml2-include=/usr/include/libxml2/libxml --with-xslt-lib=/usr/lib64 --with-xslt-include=/usr/include/libxslt $ gem install rails gem install rails wget https://rubygems-china.oss.aliyuncs.com/gems/rails-4.2.0.gem gem install rails $ rails -v |
安装Imagick ,Rmagic
ImageMagick | ImageMagick-6.7.7-0.tar.gz | 6.7.7 |
Prerequisites
$sudo yum –y install gcc $sudo yum –y install pcre-devel openssl openssl-devel $sudo yum install libjpeg $sudo yum install libjpeg-devel $sudo yum install libpng $sudo yum install libpng-devel $sudo yum install giflib $sudo yum install giflib-devel $sudo yum install freetype $sudo yum install freetype-devel $sudo yum install libtiff $sudo yum install libtiff-devel $sudo yum install –y jasper $sudo yum install –y jasper-devel $./configure $make $sudo make install |
安装RMagic
$C_INCLUDE_PATH=/usr/local/include/ImageMagick/ $export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig $gem install rmagick |
二.升级Redmine
redmine | \192.168.1.24SourceForge edmine2.6.1 | 2.6.1 |
1. Unzip redmine
put \192.168.1.24SourceForge edmine2.6.1* /opt/install/redmine cd /opt/install/redmine unzip redmine-2.6.1.tar.gz mv redmine_agile-1_3_5-light.zip /opt/install/redmine/redmine-2.6.1/plugins mv redmine_checklists-3_0_2-light.zip /opt/install/redmine/redmine-2.6.1/plugins mv redmine_ckeditor-master.zip /opt/install/redmine/redmine-2.6.1/plugins mv redmine_people-0_1_8-light.zip /opt/install/redmine/redmine-2.6.1/plugins mv redmine_per_project_formatting-master.zip /opt/install/redmine/redmine-2.6.1/plugins mv redmine_tags-master.zip /opt/install/redmine/redmine-2.6.1/plugins cd /opt/install/redmine/redmine-2.6.1/plugins unzip redmine_agile-1_3_5-light.zip unzip redmine_checklists-3_0_2-light.zip unzip redmine_ckeditor-master.zip mv r redmine_ckeditor-master. redmine_ckeditor- unzip redmine_people-0_1_8-light.zip unzip redmine_per_project_formatting-master.zip mv redmine_per_project_formatting-master. redmine_per_project_formatting unzip redmine_tags-master.zip mv redmine_tags-master redmine_tags |
2.backup and create database
./mysqldump -u redmine -p2011rEdMIne1218 redmine | gzip > /opt/backup/redmine/redmine_`date +%y_%m_%d`.gz drop database redmine_261; create user redmine_261 identified by '2011rEdMIne1218' ; grant all privileges on *.* to 'redmine_261'@'%' identified by '*******' with grant option; flush privileges; |
3.Configuration
$cd /opt/install/redmine/ $cd config $cp database.yml.example database.yml $vi database.yml (注意:冒号后要添加一个空格) production: adapter: mysql2 database: redmine host: localhost username: redmine password: my_password $cd /opt/app/redmine $gem install bundler $sudo yum –y install mysql-devel vi /home/conversant/.rvm/gems/ruby-2.0.0-p598/gems/mysql2-0.3.17/ext/mysql2/extconf.rb ---add mysql2 lib dir $gem install mongrel –pre $cd /opt/app/redmine $vi Gemfile.local # Gemfile.local $scp –r $OLD_REDMINE_HOME/files conversant@192.168.1.23:/opt/app/redmine $bundle install --without development test bundle exec rake generate_secret_token bundle exec rake db:migrate RAILS_ENV=production RAILS_ENV=production rake redmine:load_default_data bundle exec rake redmine:plugins NAME=redmine_agile RAILS_ENV=production bundle exec rake redmine:plugins NAME=redmine_people RAILS_ENV=production bundle exec rake redmine:plugins NAME=redmine_checklists RAILS_ENV=production bundle exec rake redmine:plugins:migrate RAILS_ENV=production bundle exec rake tmp:cache:clear tmp:sessions:clear RAILS_ENV=production |
4.Start&Stop
./start.sh $ps aux | grep ruby $kill -9 &pid |
Others
1.全新Install
DB
drop database redmine; create database redmine; create user redmine identified by 'redmine'; grant all privileges on *.* to 'redmine'@'%' identified by 'redmine' with grant option; |
1.2 Configuration
cd /opt/install/redmine/
gem install bundler
sudo yum -y install mysql-devel
bundle install --without development test
: I failed to put a space between password: and my_password
vi /home/conversant/.rvm/gems/ruby-2.0.0-p598/gems/mysql2-0.3.17/ext/mysql2/extconf.rb ---add mysql2 lib dir
rake generate_secret_token
RAILS_ENV=production rake db:migrate
RAILS_ENV=production rake redmine:load_default_data
ruby script/rails server webrick -e production>log/production.log &
ruby script/rails server mongrel -e production -p 4000
4.Plugins 安装日志
Agile
Unzip plugin into ./plugins/. This would result in a directory-path like: Go to redmine root folder (ex. cd /var/www/redmine) Install dependent ruby gems by following command: bundle install --without development test Migrate database and copy assets by following command: bundle exec rake redmine:plugins NAME=redmine_agile RAILS_ENV=production You now need to restart Redmine so that it shows the newly installed plugin in the list of installed plugins ("Administration -> Plugins"). Go to "Administration -> Agile" and setup plugin global settings. |
People
Unzip it into ../plugins/. This would result in a directory-path like:../plugins/redmine_people/init.rb Install dependent ruby gems by following command: bundle install --without development test Migrate database and copy assets by following command: bundle exec rake redmine:plugins NAME=redmine_people RAILS_ENV=production You now need to restart Redmine so that it shows the newly installed plugin in the list of installed plugins ("Administration -> Plugins"). Go to "Administration -> Plugins -> Redmine People plugin" and setup plugin global settings. |
Tags
Clone this repository into redmine/plugins/redmine_tags Install dependencies and migrate database: cd redmine/ bundle install RAILS_ENV=production rake redmine:plugins:migrate |
Checklists
Unzip it into ../plugins/. This would result in a directory-path like:../plugins/redmine_checklists/init.rb Migrate database and copy assets by following command: bundle exec rake redmine:plugins NAME=redmine_checklists RAILS_ENV=production You now need to restart Redmine so that it shows the newly installed plugin in the list of installed plugins ("Administration -> Plugins"). Go to "Administration -> Plugins -> Redmine Checklists plugin" and setup plugin global settings. |
Ckeditor
1.Copy the plugin directory into the plugins directory (make sure the name is redmine_ckeditor) 2.Install the required gems 3.Execute migration 4.Start Redmine 5.Change text formatting (Administration > Settings > General > Text formatting) to CKEditor 6.Configure the plugin (Administration > Plugins > Configure) |