标签:代码审核
Apache+SVN+Review Board代码审核服务器搭建流程
代码审查(CodeReview)不但可以提高质量,而且还是一个知识共享和指导的极好的手段。ReviewBoard是一款比较优秀的,开源的基于WEB的代码审查工具。
yum -y install gcc gcc-c++ make cmake autoconfautomake libffi libffi-devel ncurses* bison* zlib* expat* openssl* apr* neon*
yum -y install httpd httpd-devel
yum -y install mysql mysql-server mysql-devel mysql-python service mysqld start
登录MySQL创建reviewboard数据库和reviewboard用户
mysql –uroot –p >create database reviewboard default charset utf8collate utf8_general_ci; >grant all on reviewboard.* to‘reviewboard‘@‘localhost‘ identified by ‘reviewboard‘;
yum -y install memcached python-memcached service memcached start
yum -y install patch
yum -y install python python-devel
如果python版本为2.6(CentOS6.x),可以采用EPEL yum源进行下载
(1)、 rpm -ivh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm yum -y installpython-subvertpy pysvn
(安装yum源EPEL红帽企业库,centos默认yum源库中没有pysvn)
(2)、 yum --enablerepo=epel install pysvnpython-subvertpy
(指定在EPEL yum源中,下载pysvn,python-subvertpy)
CentOS7.x 安装EPEL源
rpm -ivhhttp://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
distribute从0.7版本后就和setuptools合并在一起了,所以先删除旧版(setuptools)easy_install。
第一步:删除easy_install
rm -f /usr/bin/easy_install* rm -f /usr/local/bin/easy_install*
第二步:安装distribute
wget https://svn.apache.org/repos/asf/oodt/tools/oodtsite.publisher/trunk/distribute_setup.py python distribute_setup.py rm distribute_setup.py
easy_install reviewboard rb-site install /var/www/html/reviewboard
根据情况配置以下内容
Domain Name: 192.168.2.41 Root Path [/]: Database Type: mysql Database Name [reviewboard]: Database Server [localhost]: Database Username: reviewboard Database Password: Confirm Database Password: Memcache Server [localhost:11211]: Username [admin]: admin Password: Confirm Password: E-Mail Address: public@unilifemedia.com Company/Organization Name (optional): unilifemedia Allow us to collect support data? [Y/n]:
chown -R apache.apache/var/www/html/reviewboard/htdocs/ chown -R apache.apache /var/www/html/reviewboard/data
把apache-wsgi.conf配置文件放到Apache的conf.d目录下
cp /var/www/html/reviewboard/conf/apache-wsgi.conf/etc/httpd/conf.d/
配置允许访问reviewboard的域名或IP
vi/var/www/html/reviewboard/conf/settings_local.py
ALLOWED_HOSTS =[‘192.168.2.41‘,‘codereviewboard.unilifemedia.com‘]
重启Apache
service httpd restart
输入刚才配置的admin密码
输入名称,SVN仓库地址,用户名密码。
Apache+SVN+Review Board代码审核服务器搭建流程
标签:代码审核
原文地址:http://12676522.blog.51cto.com/12666522/1929856