Windows平台安装Bugzilla(下)

来源:互联网 发布:像素大厨 mac安装 编辑:程序博客网 时间:2024/04/29 09:53
前部分内容

3. 安装Active Perl

运行ActivePerl-5.8.8.817-MSWin32-x86-257965.msi安装Perl. 全部选择默认值即可. 安装完成后, 用cmd命令进入操作系统的命令行下. 依次输入如下的命

令:
ppm(回车)
rep add Bugzilla http://landfill.bugzilla.org/ppm(回车)
install AppConfig(回车)
install TimeDate(回车)
install DBI(回车)
install DBD-mysql(回车)
install Template-Toolkit(回车)
install MailTools(回车)
install GD(回车)
install Chart(回车)
install GDGraph(回车)
install PatchReader(回车)

注意上面的install命令需要区分大小, 执行每个install命令可能需要一段时间, 请等待上一个命令执行完看到ppm>提示符后再输入下一个命令.

4. 配置Bugzilla

用cmd命令进入操作系统的命令行. 然后进入到Bugzilla解压后的文件夹下. 这里假设为C:/Bugzilla. 然后执行perl checksetup.pl(回车). 基本效果如下:

C:/bugzilla>perl checksetup.pl

Checking perl modules ...
Checking for       AppConfig (v1.52)   ok: found v1.55
......................
Checking for     PatchReader (v0.9.4)  ok: found v0.9.5

......................
C:/bugzilla>

命令执行完毕后, 用文本方式打开Bugzilla目录下的localconfig文件(C:/Bugzilla/localconfig).(如果运行前面的perl checksetup.pl没有成功, 就不会

生成localconfig文件). 编辑如下的内容:
========================================================================
#
# How to access the SQL database:
#
# 下面设置数据库的访问信息
$db_host = "localhost";         # where is the database?
$db_port = 3306;                # which port to use
$db_name = "bugs";              # name of the MySQL database
$db_user = "bugs";              # user to attach to the MySQL database 前面授权的用户名

#
# Enter your database password here. It's normally advisable to specify
# a password for your bugzilla database user.
# If you use apostrophe (') or a backslash (/) in your password, you'll
# need to escape it by preceding it with a / character. (/') or (//)
# 设置授权用户的密码
$db_pass = 'secpsd';
==========================================================================

设置完毕后, 再次进入命令行响应目录下运行perl checksetup.pl命令.

C:/bugzilla>perl checksetup.pl

Checking perl modules ...
..................

The following Perl modules are optional:
.................

Most ActivePerl modules are available at Apache's ppm repository.
A list of mirrors is available at
    http://www.apache.org/dyn/closer.cgi/perl/win32-bin/ppms/
You can add the repository with the following command:
    ppm rep add apache http://www.apache.org/dist/perl/win32-bin/ppms/

Checking user setup ...
............
Precompiling templates ...
Checking for    MySQL Server (v3.23.41) ok: found v4.0.20a-debug

Creating table user_group_map ...
...........................

Looks like we don't have an administrator set up yet.  Either this is your
first time using Bugzilla, or your administrator's privileges might have
accidently been deleted.

// 注意这里要求你输入Bugzilla系统管理员的EMAIL地址(Bugzilla是基于邮件通知的)
Enter the e-mail address of the administrator: byron@example.com

//确认邮件地址
You entered 'byron@example.com'.  Is this correct? [Y/n] y

// 输入管理员名字
Enter the real name of the administrator: Byron Jones

// 管理员密码
Enter a password for the administrator account: beef

// 密码确认
Please retype the password to verify: beef

'byron@example.com' is now set up as an administrator account.

C:/bugzilla>

到此,Bugzilla系统内部的设置基本完成了


5. 配置Bugzilla的Web系统

Bugzilla是基于Web浏览,所以需要Web服务器才能运行,在Windows下可以使用IIS进行管理. 进入控制面板, 打开管理工具找到Internet Information

Server(Internet信息服务), 如果没有这个工具说明操作系统还没有安装这个工具, 需要在控制面板下通过Add/Remove Component(添加删除组件) 安装IIS工

具. 在默认Web站点子项点击右键选择新键虚拟目录, 在向导的第二步中输入目录名称Bugzilla. 然后下一步选择目录的路径, 就Bugzilla的解压路径(前面假设

为C:/Bugzilla). 接着下一步的权限设置中除了默认的前面两个选择外, 还有选择第三个执行. 然后完成IIS配置的向导.

接着在默认Web站点下会多一个我们刚才输入的虚拟目录名称子项. 在它上面点击右键打开属性设置对话框. 在第二个标签的文档中, 选中启用默认文档, 通过删

除按纽删除原来所有的文档名称, 然后添加一个名称为index.cgi的文档.

回到属性框的第一个标签页虚拟目录中, 选择配置按钮, 打开应用程序配置对话框, 选择添加按钮, 在弹出对话框设置如下内容:
可执行文件: C:/Perl/bin/perl.exe -xC:/Bugzilla -wT "%s" %s
// 注意上面的路径需要根据实际情况改变
扩展名: .cgi
动作: 限于----GET,HEAD,POST
最后选中脚本引擎确定即可.

6. 安装Bugzilla邮件系统

最后需要安装的是邮件系统,默认情况下Bugzilla是采用Sendmail进行邮件的发送,我们需要从网上下载sendmail的专门为bugzilla制作的windows安装版本

sendmail-bugzilla-setup.exe,安装这个程序后,需要根据实际情况设置邮件服务器,设置非常的简单,在安装完成后的程序目录下有名称为sengmail.ini邮

件配置文件,可以设置如下内容:
[sendmail]
; smtp服务器的地址
smtp_server=192.168.0.251
; 默认的域名,也就是邮件中@字母后的部分
default_domain=system.mail
; 是否打开错误的日志功能
error_logfile=error.log
; 是否打开调试日志功能
;debug_logfile=debug.log
; Bugzilla发送邮件时使用的用户名和密码
auth_username=Bugzilla
auth_password=Bugzilla
; 设置pop3服务器,用户名,密码
pop3_server=192.168.0.251
pop3_username=Bugzilla
pop3_password=Bugzilla

现在所有的功能都安装完成了,打开浏览器,输入localhost/bugzilla就可以开始使用bugzilla了。享受吧!


原创粉丝点击