linux系統中bugzilla nginx 安裝配置 詳解

來源:互聯網
上載者:User

在網上看了一下,bugzilla的安裝,大部分的web環境是apache 。下面說一下我的安裝過程。
一,安裝epel源
請參考:centos 推薦使用epel源
二,安裝mysql nginx bugzilla,以及相關工具
yum install mysql mysql-server bugzilla fcgi-devel fcgi nginx perl spawn-fcgi 
安裝fcgiwrap,它是用來運行perl的cgi程式的
fcgiwrap下載地址: http://github.com/gnosek/fcgiwrap/tarball/master
[root@localhost download]# tar zxvf gnosek-fcgiwrap-1.1.0-5-g66e7b7d.tar.gz 
[root@localhost download]# cd gnosek-fcgiwrap-66e7b7d/ 
[root@localhost gnosek-fcgiwrap-66e7b7d]# autoreconf -i 
[root@localhost gnosek-fcgiwrap-66e7b7d]# ./configure 
[root@localhost gnosek-fcgiwrap-66e7b7d]# make 
gcc -std=gnu99 -Wall -Wextra -Werror -pedantic -O2 -g3 fcgiwrap.c -o fcgiwrap -lfcgi 
[root@localhost gnosek-fcgiwrap-66e7b7d]# cp fcgiwrap /usr/local/bin/ 
如果autoreconf -i時,autoreconf命令不存在,安裝如下依賴包:
yum install patch gcc-c++ readline-devel zlib-devel libffi-devel openssl-devel make autoconf automake libtool bison libxml2-devel libxslt-devel libyaml-devel 
三,啟動mysql,並建立bugzilla資料庫
查看複製列印?
/etc/init.d/mysqld start   //啟動服務端 
 
mysql> create database bugstest;    //建立空資料庫 
mysql> grant all privileges on bugstest.* TO 'bugstest'@'localhost' IDENTIFIED BY 'bugstest';   //分配許可權 
mysql> flush privileges; 
四,修改bugzilla的配置localconfig,並且安裝bugzilla資料庫
1,修改/etc/localconfig
查看複製列印?
$db_name = 'bugstest';      //資料庫名 
$db_user = 'bugstest';      //串連使用者名稱 
$db_pass = 'bugstest';        //串連密碼 
就是上面,mysql裡面添加的使用者。
2,安裝bugzilla資料庫,執行checksetup.pl
cd /usr/share/bugzilla/ 
./checksetup.pl 
在安裝過程中會提示你輸入administrtor的使用者名稱和密碼,注意:安裝成功後,登入的使用者名稱,是你的郵箱。
五,nginx配置
1,copy bugzilla到www目錄下
查看複製列印?
cp -r /usr/share/bugzilla /var/www/html/ 
chown nginx:nginx -R /var/www/html/bugzilla   //改成nginx的啟動使用者 
2,建一個nginx的vhost
查看複製列印?
[root@localhost conf.d]# cat bugzilla.conf 
server 

    listen       80; 
    server_name  192.168.10.202; 
    index  index.cgi index.html; 
    root   /var/www/html/bugzilla; 
 
    location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$ 
    { 
        expires     30d; 
    } 
 
    location ~ .*\.(js|css)?$ 
    { 
        expires     1h; 
    } 
 
    location ~ .*\.cgi$ { 
             fastcgi_pass          127.0.0.1:9001; 
             fastcgi_index         index.cgi; 
             include            fastcgi.conf; 
    } 

六,啟動nginx和fcgiwrap
查看複製列印?
spawn-fcgi -f /usr/local/bin/fcgiwrap -a 127.0.0.1 -p 9001 -F 3 -P /var/run/fastcgi-c.pid 
 
/etc/init.d/nginx start 
效果圖:

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.