Difference between revisions of "How to setup bugzilla"

From ThorstensHome
Jump to: navigation, search
(Configure your bugzilla)
 
m (1 revision(s))
 

Latest revision as of 10:09, 18 October 2008

This article describes how to set up bugzilla on SUSE 9.2 with apache2.

  1. have the following packages installed:
      • perl-AppConfig
      • perl-CGI-Application
      • perl-DateManip
      • perl-Template-Toolkit
      • perl-TimeDate
      • perl-GD
      • perl-GDGraph
      • perl-GDTextUtil
      • perl-XML-Parser
  2. Download the latest bugzilla from http://www.bugzilla.org/, this tutorial assumes it is version 2.18rc2.
  3. install it
  4. tar xvfz bugzilla-2.18rc2.tar.gz
    cd bugzilla-2.18rc2
    ./checksetup.pl
    
  5. Configure mysql like this. This tutorial assumes the password P3 (not shown).
  6. scorpio:~/bugzilla-2.18rc3 # mysql_secure_installation
    
    
    
    
    NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL
          SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!
    
    
    In order to log into MySQL to secure it, we'll need the current
    password for the root user.  If you've just installed MySQL, and
    you haven't set the root password yet, the password will be blank,
    so you should just press enter here.
    
    Enter current password for root (enter for none):
    OK, successfully used password, moving on...
    
    Setting the root password ensures that nobody can log into the MySQL
    root user without the proper authorisation.
    
    Set root password? [Y/n] Y
    New password:
    Re-enter new password:
    Password updated successfully!
    Reloading privilege tables..
     ... Success!
    
    
    By default, a MySQL installation has an anonymous user, allowing anyone
    to log into MySQL without having to have a user account created for
    them.  This is intended only for testing, and to make the installation
    go a bit smoother.  You should remove them before moving into a
    production environment.
    
    Remove anonymous users? [Y/n] Y
     ... Success!
    
    Normally, root should only be allowed to connect from 'localhost'.  This
    ensures that someone cannot guess at the root password from the network.
    
    Disallow root login remotely? [Y/n] Y
     ... Success!
    
    By default, MySQL comes with a database named 'test' that anyone can
    access.  This is also intended only for testing, and should be removed
    before moving into a production environment.
    
    Remove test database and access to it? [Y/n] Y
     - Dropping test database...
     ... Success!
     - Removing privileges on test database...
     ... Success!
    
    Reloading the privilege tables will ensure that all changes made so far
    will take effect immediately.
    
    Reload privilege tables now? [Y/n] Y
     ... Success!
    
    Cleaning up...
    
    
    
    All done!  If you've completed all of the above steps, your MySQL
    installation should now be secure.
    
    Thanks for using MySQL!
    
    
    scorpio:~/bugzilla-2.18rc3 #             
    
  7. priviledge the bugzilla-mysql-user like this:
  8. scorpio:~/bugzilla-2.18rc3 # mysql --password=P3
    Welcome to the MySQL monitor.  Commands end with ; or g.
    Your MySQL connection id is 21 to server version: 4.0.21-Max 
    
    Type 'help;' or 'h' for help. Type 'c' to clear the buffer.
    
    mysql> GRANT ALL PRIVILEGES ON bugs.* TO bugs@localhost IDENTIFIED BY 'P6';
    Query OK, 0 rows affected (0.00 sec)
    
    mysql> FLUSH PRIVILEGES;
    Query OK, 0 rows affected (0.04 sec) 
    
    mysql> exit
    Bye
    scorpio:~/bugzilla-2.18rc3 #
    
  9. install perl-modules online:
  10. perl -MCPAN -e shell 
    

    type RETURN 25 times, reply to the question of that program

  11. The program presents you a "cpan shell". Do the following:
  12. cpan shell -- CPAN exploration and modules installation (v1.7601)
    ReadLine support enabled 
    
    cpan> install Bundle::CPAN
    CPAN: Storable loaded ok
    LWP not available
    Fetching with Net::FTP:
      ftp://ftp.uni-erlangen.de/pub/source/CPAN/authors/01mailrc.txt.gz
    
    
  13. Still in the cpan-shell, do install PatchReader and install Chart::Base and exit
  14. change localconfig, replace $webservergroup="apache" by $webservergroup="www" and $db_pass= by $db_pass='P6'
  15. Let the software check itself:
  16. ./checksetup.pl
    
    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. 
    Enter the e-mail address of the administrator: me@home.de
    You entered 'me@home.de'.  Is this correct? [Y/n] Y
    Enter the real name of the administrator: Tim Thaler
    Enter a password for the administrator account:
    Please retype the password to verify:
    'me@home.de' is now set up as an administrator account.
    scorpio:~/bugzilla-2.18rc3 #           
    
  17. move the bugzilla-folder to /srv/www/htdocs/bugzilla
  18. enable your webserver to execute from that folder:
  19. chgrp www /srv/www/htdocs/bugzilla
    chmod g+x /srv/www/htdocs/bugzilla
    
  20. in /etc/apache2/httpd.conf" have the line "DirectoryIndex index.php index.html index.html.var index.cgi". Within <Directory /> and </ Directory>, outcomment Options None and set AllowOverride All.
  21. in /etc/apache2/default-server.conf, have "AllowOverride All", outcomment "Options None". Place the following line directly after DocumentRoot: "AddHandler cgi-script .cgi".
  22. /etc/init.d/apache2 restart
  23. try it out: http://127.0.0.1/bugzilla
  24. Configure your bugzilla

  25. Configuration steps:
    1. log in
    2. click onto Parameters
    3. set Maintainer, urlbase (e.g. www.mysite.de/bugzilla), createemailregexp, requirelogin.
    4. click onto submit
  26. make your bugzilla writing statistics:
  27.       crontab -e, insert
    
    5 0 * * * cd /srv/www/htdocs/bugzilla ; ./collectstats.pl
    
  28. /etc/init.d/cron restart
  29. Issue cd /srv/www/htdocs/bugzilla/ && ./collectstats.pl && echo success. Expected result: The command outputs "success".
  30. You may want to configure your sendmail:
    1. sendmail -t me@home.de
    2. mailq
    3. postqueue -f
    4. cat /etc/postfix/main.cf|grep recipient_restriction
    5. have your own name in /etc/postfix/main.cf, then it looks like
    6. scorpio:/etc # mailq
      -Queue ID- --Size-- ----Arrival Time---- -Sender/Recipient-------
      B66CD5497*      271 Sat Jan 15 23:45:03  root@site.site
                                               you@domain.de
      
      -- 0 Kbytes in 1 Request.
      scorpio:/etc # 
      

How do you like this site?

© http://www.usegroup.de