Skip to main content

[转] centos 安装 bugzilla

转载本站文章请注明,转载自:扶凯[http://www.php-oa.com]

本文链接: http://www.php-oa.com/2007/12/21/linux-bugzilla-centos/


转载的话,请注明来自己www.php-oa.com

bugzilla是用的最多,很不错的bug跟踪系统,但他的安装难到了不少人.这边我写了一个简单安装指南.

安装配置Bugzilla 3

1.安装http,mysql等

yum install gd gd-devel httpd mysqld gcc g++ make

rpm -Uhv http://apt.sw.be/packages/rpmforge-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm
上面是加入第三方扩展源,有很多包别人编译好了,我们可以直接使用.

yum install perl-XML-Twig
yum install ImageMagick-perl
yum install mod_perl
yum install perl-HTML-Parser
yum install perl-Email-MIME-Attachment-Stripper
yum install perl-Chart
yum install perl-PatchReader

yum install perl-Net-LDAP

2.生成Bugzilla数据库用户并分配权限
mysql -uroot -p

mysql>create database bugs DEFAULT CHARACTER SET utf8

mysql>GRANT SELECT, INSERT, UPDATE, DELETE, INDEX, ALTER, CREATE, LOCK TABLES, CREATE TEMPORARY TABLES, DROP, REFERENCES ON bugs.* TO bugs@localhost IDENTIFIED BY 'passwd';

3.下载安装Bugzilla,下载安装Perl模块

首先检查相应的perl模块是否已经安装完毕:
./checksetup.pl --check-modules

会出现如下的内容

安装必需的perl包:
/usr/bin/perl -MCPAN -e 'install Email::Send'
/usr/bin/perl -MCPAN -e 'install Template'
/usr/bin/perl -MCPAN -e 'install Email::MIME::Modifier'

安装可选的perl包:
/usr/bin/perl -MCPAN -e 'install GD::Graph'
/usr/bin/perl -MCPAN -e 'install Template::Plugin::GD::Image'
/usr/bin/perl -MCPAN -e 'install Email::Reply'
/usr/bin/perl -MCPAN -e 'install Email::MIME::Attachment::Stripper'
/usr/bin/perl -MCPAN -e 'install HTML::Scrubber'
/usr/bin/perl -MCPAN -e 'install XML::Twig'
/usr/bin/perl -MCPAN -e 'install Chart::Base'
/usr/bin/perl -MCPAN -e 'install Apache::DBI'

少了那个,就用命令安装就好了:命令就是 perl -MCPAN -e '包名'

都OK了的话.

修改localconfig文件,设置数据库访问方式
更改localconfig的以下设置:
$db_pass = '';

$db_pass = 'passwd';

再次运行CheckSetup.pl完成数据库初始化

4.在IIS管理器中为Bugzilla建立虚拟路径

最后,配置apache服务器,使Bugzilla 3以后可用。这一步只需添加以下文件即可:
/etc/httpd/conf.d/bugzilla.conf
文件/etc/httpd/conf.d/bugzilla.conf的内容如下:

#
# This configuration file is bugzilla.
#

Alias /bugzilla "/var/www/bugzilla"


AddHandler cgi-script .cgi
Options +Indexes +ExecCGI
DirectoryIndex index.cgi
AllowOverride Limit
Order allow,deny
Allow from all

添加安apache配置文件后,需要重启httpd,如果重启后不能生效,可能需要重启一下服务器主机:
service httpd restart

6. 配置,汉化Bugzilla

http://IP/bugzilla

如果能看到页面,则基本可以确定Bugzilla 3安装正常,可以正常使用了。如果需要定制Bugzilla 3,请以系统管理员登录Bugzilla 3,进行相应定制设置即可。
记的要用你设置的邮件地址做管理员的名字哦。我原来用安装时设置的名字一直不行,后来才发现.

Bugzilla的汉化其实很简单。
登录sourceforge,而bugzilla汉化项目bugzilla-cn在sourceforge上。
下载下来后,把 cn_UTF8.zip里的default目录放到template/en里,并更名为custom。

注:我不知为什么设置了管理员密码不生效,如果忘记了super user的密码。没有可反向解析的ip,意味着sendmail发的信到不了目的地。
这样注册的新用户就得不到注册时随机产生的密码。
要解决这个问题,可以把data/params里的mail_delivery_method改成testfile,这样就不会通过MTA来发信,而是把 信件内容保存在 data/mailer.testfile里。这样就的到了一个可用的普通用户。然后在mysql控制台里,把bugs数据库里的profiles表里的 这个用户的userid改成1,那么这个用户就变成了super user。

Comments

Popular posts from this blog

[转] UTF-8 and Unicode FAQ for Unix/Linux

这几天,这个东西把我搞得很头疼 而且这篇文章好像太大了,blogger自己的发布系统不能发 只好用mail了 //原文 http://www.cl.cam.ac.uk/~mgk25/unicode.html UTF-8 and Unicode FAQ for Unix/Linux by Markus Kuhn This text is a very comprehensive one-stop information resource on how you can use Unicode/UTF-8 on POSIX systems (Linux, Unix). You will find here both introductory information for every user, as well as detailed references for the experienced developer. Unicode has started to replace ASCII, ISO 8859 and EUC at all levels. It enables users to handle not only practically any script and language used on this planet, it also supports a comprehensive set of mathematical and technical symbols to simplify scientific information exchange. With the UTF-8 encoding, Unicode can be used in a convenient and backwards compatible way in environments that were designed entirely around ASCII, like Unix. UTF-8 is the way in which Unicode is used under Unix, Linux, and similar systems. It is now time to make sure that you are well familiar ...

Determine Perspective Lines With Off-page Vanishing Point

In perspective drawing, a vanishing point represents a group of parallel lines, in other words, a direction. For any point on the paper, if we want a line towards the same direction (in the 3d space), we simply draw a line through it and the vanishing point. But sometimes the vanishing point is too far away, such that it is outside the paper/canvas. In this example, we have a point P and two perspective lines L1 and L2. The vanishing point VP is naturally the intersection of L1 and L2. The task is to draw a line through P and VP, without having VP on the paper. I am aware of a few traditional solutions: 1. Use extra pieces of paper such that we can extend L1 and L2 until we see VP. 2. Draw everything in a smaller scale, such that we can see both P and VP on the paper. Draw the line and scale everything back. 3. Draw a perspective grid using the Brewer Method. #1 and #2 might be quite practical. #3 may not guarantee a solution, unless we can measure distances/p...

Moving Items Along Bezier Curves with CSS Animation (Part 2: Time Warp)

This is a follow-up of my earlier article.  I realized that there is another way of achieving the same effect. This article has lots of nice examples and explanations, the basic idea is to make very simple @keyframe rules, usually just a linear movement, then use timing function to distort the time, such that the motion path becomes the desired curve. I'd like to call it the "time warp" hack. Demo See the Pen Interactive cubic Bezier curve + CSS animation by Lu Wang ( @coolwanglu ) on CodePen . How does it work? Recall that a cubic Bezier curve is defined by this formula : \[B(t) = (1-t)^3P_0+3(1-t)^2tP_1+3(1-t)t^2P_2+t^3P_3,\ 0 \le t \le 1.\] In the 2D case, \(B(t)\) has two coordinates, \(x(t)\) and \(y(t)\). Define \(x_i\) to the be x coordinate of \(P_i\), then we have: \[x(t) = (1-t)^3x_0+3(1-t)^2tx_1+3(1-t)t^2x_2+t^3x_3,\ 0 \le t \le 1.\] So, for our animated element, we want to make sure that the x coordiante (i.e. the "left" CSS property) is \(...