Fedora 25 安装 Bugzilla

最近领导要我们装一个Bugzulla,虽然我们项目已经有了JIRA(我就呵呵),不过我还是找些资料安装了,在此备忘。

Bugzilla 是一个开源的缺陷跟踪系统(Bug-Tracking System),它可以管理软件开发中缺陷的提交(new),修复(resolve),关闭(close)等整个生命周期。

首先下载Bugzulla: yum install bugzilla -y。(我这里没有安装dnf,dnf在fedora 22 时取代了yum)

安装成功后我们cd到/usr/share/bugzilla目录中去,我们可以看到一个checksetup.pl 可执行程序,运行它。顾名思义它是帮你检查本地环境及启动bugzulla的脚本,

其会提示你本地还需要的依赖包,你一一安装即可。

[root@dai bugzilla]# ./checksetup.pl
* This is Bugzilla 5.0.3 on perl 5.24.3
* Running on Linux 4.13.16-100.fc25.x86_64 #1 SMP Mon Nov 27 19:52:46 UTC 2017

Checking perl modules...
Checking for               CGI.pm (v3.51)     ok: found v4.32
Checking for           Digest-SHA (any)       ok: found v6.00
Checking for             TimeDate (v2.23)     ok: found v2.24
Checking for             DateTime (v0.75)     ok: found v1.42
Checking for    DateTime-TimeZone (v1.64)     ok: found v2.15
Checking for                  DBI (v1.614)    ok: found v1.636
Checking for     Template-Toolkit (v2.24)     ok: found v2.26
Checking for         Email-Sender (v1.300011) ok: found v1.300028
Checking for           Email-MIME (v1.904)    ok: found v1.937
Checking for                  URI (v1.55)     ok: found v1.71
Checking for       List-MoreUtils (v0.32)     ok: found v0.416
Checking for    Math-Random-ISAAC (v1.0.1)    ok: found v1.004
Checking for              JSON-XS (v2.01)     ok: found v3.02

Checking available perl DBD modules...
Checking for            DBD-mysql (v4.001)    ok: found v4.043
Checking for               DBD-Pg (v2.7.0)    ok: found v3.5.3
Checking for           DBD-SQLite (v1.29)     not found
Checking for           DBD-Oracle (v1.19)     not found

The following Perl modules are optional:
Checking for                   GD (v1.20)     ok: found v2.56
Checking for                Chart (v2.4.1)    ok: found v2.4.10
Checking for          Template-GD (any)       ok: found v1.56
Checking for           GDTextUtil (any)       ok: found v0.86
Checking for              GDGraph (any)       ok: found v1.53
Checking for           MIME-tools (v5.406)    ok: found v5.508
Checking for          libwww-perl (any)       ok: found v6.15
Checking for             XML-Twig (any)       ok: found v3.52
Checking for          PatchReader (v0.9.6)    ok: found v0.9.6
Checking for            perl-ldap (any)       ok: found v0.65
Checking for          Authen-SASL (any)       ok: found v2.16
Checking for         Net-SMTP-SSL (v1.01)     ok: found v1.03
Checking for           RadiusPerl (any)       ok: found v0.24
Checking for            SOAP-Lite (v0.712)    ok: found v1.20
Checking for          XMLRPC-Lite (v0.712)    ok: found v0.717
Checking for             JSON-RPC (any)       not found
Checking for           Test-Taint (v1.06)     ok: found v1.06
Checking for          HTML-Parser (v3.67)     ok: found v3.72
Checking for        HTML-Scrubber (any)       ok: found v0.15
Checking for               Encode (v2.21)     ok: found v2.88
Checking for        Encode-Detect (any)       ok: found v1.01
Checking for          Email-Reply (any)       ok: found v1.204
Checking for HTML-FormatText-WithLinks (v0.13)     ok: found v0.15
Checking for          TheSchwartz (v1.07)     ok: found v1.12
Checking for       Daemon-Generic (any)       ok: found v0.84
Checking for             mod_perl (v1.999022) ok: found v2.000010
Checking for     Apache-SizeLimit (v0.96)     ok: found v0.97
Checking for        File-MimeInfo (any)       ok: found v0.27
Checking for           IO-stringy (any)       ok: found v2.111
Checking for      Cache-Memcached (any)       ok: found v1.30
Checking for  File-Copy-Recursive (any)       ok: found v0.38
Checking for           File-Which (any)       ok: found v1.21
Checking for              mod_env (any)       ok
Checking for          mod_expires (any)       ok
Checking for          mod_headers (any)       ok
Checking for          mod_rewrite (any)       ok
Checking for          mod_version (any)       ok
***********************************************************************
* OPTIONAL MODULES                                                    *
***********************************************************************
* Certain Perl modules are not required by Bugzilla, but by           *
* installing the latest version you gain access to additional         *
* features.                                                           *
*                                                                     *
* The optional modules you do not have installed are listed below,    *
* with the name of the feature they enable. Below that table are the  *
* commands to install each module.                                    *
***********************************************************************
* MODULE NAME * ENABLES FEATURE(S)                                    *
***********************************************************************
*    JSON-RPC * JSON-RPC Interface, REST Interface                    *
***********************************************************************
COMMANDS TO INSTALL OPTIONAL MODULES:

       JSON-RPC: dnf install "perl(JSON::RPC::Legacy::Server::CGI)"

Reading /etc/bugzilla/localconfig...
Checking for            DBD-mysql (v4.001)    ok: found v4.043
Checking for                MySQL (v5.0.15)   ok: found v10.1.26-MariaDB

Removing existing compiled templates...
Precompiling templates...done.
Fixing file permissions...

Now that you have installed Bugzilla, you should visit the 'Parameters'
page (linked in the footer of the Administrator account) to ensure it
is set up as you wish - this includes setting the 'urlbase' option to
the correct URL.
checksetup.pl complete.

bugzilla需要httpd和mysql的支持,启动他们。

service httpd start

service mysqld start

再次运行hecksetup.pl 可执行程序,也许你会遇到bugs不能访问的错误提示,我们需要对bugs的访问权限进行设置。

grant all privileges on bugs.* 'bugs'@'localhost';(/etcbugzillalocalconfig可以更改用户和密码,如果mtsql授权方法行不同可以将用户改为root)

再次运行hecksetup.pl 可执行程序。

现在在本机浏览器中打开http://localhost/bugzilla/即可看到bugzilla主界面。

那怎么让别的机器也可以访问呢?

编辑httpd.conf文件的 servername

vim /etc/httpd/conf/httpd.conf

# ServerName gives the name and port that the server uses to identify itself.
# This can often be determined automatically, but we recommend you specify
# it explicitly to prevent problems during startup.
#
# If your host doesn't have a registered DNS name, enter its IP address here.
#
#ServerName www.example.com:80
ServerName 192.168.1.1(本机IP):80

(若不可连接,因检查下firewalld 是否关闭)

在最后一行加入

<Directory "/var/www/html/bugzilla">
Options ExecCGI FollowSymLinks
AllowOverride Limit
Order allow,deny
Allow from all
</Directory>

保存退出即可。

http://服务器IP/bugzilla 就可打开bugzilla主界面。

以前-好记性不如烂笔头 现在-好记性不如烂键盘
原文地址:https://www.cnblogs.com/gexbooks/p/8657514.html