centos6.5安装redmine2.6
Redmine是一个开源的、基于Web的项目管理和缺陷跟踪工具。它用日历和甘特图辅助项目及进度可视化显示。同时它又支持多项目管理。Redmine是一个*开放源码软件解决方案,它提供集成的项目管理功能,问题跟踪,并为多个版本控制选项的支持。虽说像IBM Rational Team Concert的商业项目调查工具已经很强大了,但想坚持一个*和开放源码的解决方案,可能会发现Redmine是一个有用的Scrum和敏捷的选择。 由于Redmine的设计受到Rrac的较大影响,所以它们的软件包有很多相似的特征。Redmine建立在Ruby on Rails的框架之上,它可以夸平台和数据库。
环境
Remind2.6+Mysql5.5+Nginx1.8
1,安装ruby
[[email protected] ~]# wget http://cache.ruby-lang.org/pub/ruby/2.1/ruby-2.1.5.tar.gz [[email protected] ~]# tar xzf ruby-2.1.5.tar.gz [[email protected] ruby-2.1.5]# cd ruby-2.1.5 [[email protected] ruby-2.1.5]# ./configure --prefix=/usr/local/ruby [[email protected] ruby-2.1.5]# make && make install
添加到环境变量
[[email protected] ~]# vi /etc/profile export PATH=/usr/local/ruby/bin:$PATH [[email protected] ~]# source /etc/profile
查看ruby版本号
[[email protected] ~]# ruby -v ruby 2.1.5p273 (2014-11-13 revision 48405) [i686-linux]
2,安装rails
[[email protected] ~]# wget http://production.cf.rubygems.org/rubygems/rubygems-2.4.5.tgz [[email protected] ~]# tar xzf rubygems-2.4.5.tgz [[email protected] ~]# cd rubygems-2.4.5 [[email protected] rubygems-2.4.5]# ruby setup.rb [[email protected] rubygems-2.4.5]# gem -v 2.4.5 [[email protected] rubygems-2.4.5]# which gem /usr/local/ruby/bin/gem [[email protected] rubygems-2.4.5]# gem install rails -v=3.2 [[email protected] rubygems-2.4.5]# rails -v Rails 3.2.19
3,安装redmine2.6
[[email protected] ~]# wget http://www.redmine.org/releases/redmine-2.6.0.tar.gz [[email protected] ~]# tar xzf redmine-2.6.0.tar.gz -C /app [[email protected] ~]# mv /app/redmine{-2.6.0,}
创建数据库
[[email protected] ~]# cd /app/redmine [[email protected] redmine]# gem install mysql2 #用mysql2能***能 [[email protected] redmine]# mysql -uroot -ppasswd -e “create database redmine" 配置redmine的database.yml [[email protected] ~]# cd /app/redmine/config [[email protected] config]# cp database.yml.example database.yml [[email protected] config]# cat database.yum #修改对应数据库连接信息 production: adapter: mysql2 database: redmine host: localhost username: root password: “passwd" encoding: utf8
安装redmine依赖的所有ruby包
[[email protected] redmine]# gem install bundler #注意时在网站根目录下执行 [[email protected] redmine]# bundle install --without development test rmagick #完成redmine依赖包的安装 bundler是用来管理ruby的包依赖的工具
为Rails生成cookies秘钥
[[email protected] redmine]# rake generate_secret_token
创建数据库结构
[[email protected] redmine]# RAILS_ENV=production rake db:migrate
生成缺省数据
[[email protected] redmine]# RAILS_ENV=production REDMINE_LANG=zh rake redmine:load_default_data
调整文件系统权限
[[email protected] ~]# cd /app/redmine [[email protected] redmine]# mkdir -p tmp tmp/pdf public/plugin_assets [[email protected] redmine]# chown -R www.www /app/redmine/ tmp和tmp/pdf (若不存在则创建该路径,用于生成 PDF 文件);public/plugin_assets (若不存在则创建该路径,plugins资源)
4,在WEBrick服务上测试Redmine是否安装成功
[[email protected] ~]# vi /etc/passwd #使www用户有bash权限,lnmp脚本安装www用户没有bash权限 www:x:501:501::/home/www:/bin/bash [[email protected] ~]# su www -c "ruby /app/redmine/script/rails server webrick -e production -d"
地址:http://IP:3000 (注意:打开iptables 3000端口号)
缺省管理员用户:
login: admin
password: admin
如果验证成功,则继续下面的步骤来使Redmine运行在Nginx服务上
[[email protected] ~]# vim /usr/local/nginx/conf/nginx.conf server { listen 80; server_name redmine.domain.com; access_log /home/wwwlogs/access_nginx.log combined; location / { proxy_pass http://127.0.0.1:3000; } }
redmine与svn整合
管理—>配置—>版本库—>svn命令是否生效
版本库必须在项目中,所以首先要创建项目,然后在添加新的版本库
转载于:https://blog.51cto.com/charlie928/1663549