?? bugzilla-guide.txt
字號:
provides a GUI to manage Perl modules. We highly recommend that you use it. If you prefer to use ppm from the command-line, type:C:\perl> ppm install <module name> The best source for the Windows PPM modules needed for Bugzilla is probably the theory58S website, which you can add to your list of repositories as follows (for Perl 5.8.x):ppm repo add theory58S http://theoryx5.uwinnipeg.ca/ppms/ If you are using Perl 5.10.x, you cannot use the same PPM modules as Perl 5.8.x as they are incompatible. In this case, you should add the following repository:ppm repo add theory58S http://cpan.uwinnipeg.ca/PPMPackages/10xx/ Note In versions prior to 5.8.8 build 819 of PPM the command isppm repository add theory58S http://theoryx5.uwinnipeg.ca/ppms/ Note The PPM repository stores modules in 'packages' that may have a slightly different name than the module. If retrieving these modules from there, you will need to pay attention to the information provided when you run checksetup.pl as it will tell you what package you'll need to install. Tip If you are behind a corporate firewall, you will need to let the ActiveState PPM utility know how to get through it to access the repositories by setting the HTTP_proxy system environmental variable. For more information on setting that variable, see the ActiveState documentation. _________________________________________________________________2.5.1.3. Code changes required to run on Win32 Bugzilla on Win32 is supported out of the box from version 2.20; this means that no code changes are required to get Bugzilla running. _________________________________________________________________2.5.1.4. Serving the web pages As is the case on Unix based systems, any web server should be able to handle Bugzilla; however, the Bugzilla Team still recommends Apache whenever asked. No matter what web server you choose, be sure to pay attention to the security notes in Section 4.3.1. More information on configuring specific web servers can be found in Section 2.2.4. Note If using Apache on windows, you can set the ScriptInterpreterSource directive in your Apache config to avoid having to modify the first line of every script to contain your path to Perl instead of /usr/bin/perl. When setting ScriptInterpreterSource, do not forget to specify the -T flag to enable the taint mode. For example: C:\Perl\bin\perl.exe -T. _________________________________________________________________2.5.1.5. Sending Email To enable Bugzilla to send email on Windows, the server running the Bugzilla code must be able to connect to, or act as, an SMTP server. _________________________________________________________________2.5.2. Mac OS X Making Bugzilla work on Mac OS X requires the following adjustments. _________________________________________________________________2.5.2.1. Sendmail In Mac OS X 10.3 and later, Postfix is used as the built-in email server. Postfix provides an executable that mimics sendmail enough to fool Bugzilla, as long as Bugzilla can find it. As of version 2.20, Bugzilla will be able to find the fake sendmail executable without any assistance. However, you will have to turn on the sendmailnow parameter before you do anything that would result in email being sent. For more information, see the description of the sendmailnow parameter in Section 3.1. _________________________________________________________________2.5.2.2. Libraries & Perl Modules on Mac OS X Apple does not include the GD library with Mac OS X. Bugzilla needs this for bug graphs. You can use DarwinPorts (http://darwinports.com/) or Fink (http://sourceforge.net/projects/fink/), both of which are similar in nature to the CPAN installer, but install common unix programs. Follow the instructions for setting up DarwinPorts or Fink. Once you have one installed, you'll want to use it to install the gd2 package. Fink will prompt you for a number of dependencies, type 'y' and hit enter to install all of the dependencies and then watch it work. You will then be able to use CPAN to install the GD Perl module. Note To prevent creating conflicts with the software that Apple installs by default, Fink creates its own directory tree at /sw where it installs most of the software that it installs. This means your libraries and headers will be at /sw/lib and /sw/include instead of /usr/lib and /usr/include. When the Perl module config script asks where your libgd is, be sure to tell it /sw/lib. Also available via DarwinPorts and Fink is expat. After installing the expat package, you will be able to install XML::Parser using CPAN. If you use fink, there is one caveat. Unlike recent versions of the GD module, XML::Parser doesn't prompt for the location of the required libraries. When using CPAN, you will need to use the following command sequence:# perl -MCPAN -e'look XML::Parser' (1)# perl Makefile.PL EXPATLIBPATH=/sw/lib EXPATINCPATH=/sw/include# make; make test; make install (2)# exit (3) (1) (3) The look command will download the module and spawn a new shell with the extracted files as the current working directory. The exit command will return you to your original shell. (2) You should watch the output from these make commands, especially "make test" as errors may prevent XML::Parser from functioning correctly with Bugzilla. _________________________________________________________________2.5.3. Linux Distributions Many Linux distributions include Bugzilla and its dependencies in their native package management systems. Installing Bugzilla with root access on any Linux system should be as simple as finding the Bugzilla package in the package management application and installing it using the normal command syntax. Several distributions also perform the proper web server configuration automatically on installation. Please consult the documentation of your Linux distribution for instructions on how to install packages, or for specific instructions on installing Bugzilla with native package management tools. There is also a Bugzilla Wiki Page for distro-specific installation notes. _________________________________________________________________2.6. UNIX (non-root) Installation Notes2.6.1. Introduction If you are running a *NIX OS as non-root, either due to lack of access (web hosts, for example) or for security reasons, this will detail how to install Bugzilla on such a setup. It is recommended that you read through the Section 2.1 first to get an idea on the installation steps required. (These notes will reference to steps in that guide.) _________________________________________________________________2.6.2. MySQL You may have MySQL installed as root. If you're setting up an account with a web host, a MySQL account needs to be set up for you. From there, you can create the bugs account, or use the account given to you. Warning You may have problems trying to set up GRANT permissions to the database. If you're using a web host, chances are that you have a separate database which is already locked down (or one big database with limited/no access to the other areas), but you may want to ask your system administrator what the security settings are set to, and/or run the GRANT command for you. Also, you will probably not be able to change the MySQL root user password (for obvious reasons), so skip that step. _________________________________________________________________2.6.2.1. Running MySQL as Non-Root2.6.2.1.1. The Custom Configuration Method Create a file .my.cnf in your home directory (using /home/foo in this example) as follows....[mysqld]datadir=/home/foo/mymysqlsocket=/home/foo/mymysql/thesockport=8081[mysql]socket=/home/foo/mymysql/thesockport=8081[mysql.server]user=mysqlbasedir=/var/lib[safe_mysqld]err-log=/home/foo/mymysql/the.logpid-file=/home/foo/mymysql/the.pid _________________________________________________________________2.6.2.1.2. The Custom Built Method You can install MySQL as a not-root, if you really need to. Build it with PREFIX set to /home/foo/mysql, or use pre-installed executables, specifying that you want to put all of the data files in /home/foo/mysql/data. If there is another MySQL server running on the system that you do not own, use the -P option to specify a TCP port that is not in use. _________________________________________________________________2.6.2.1.3. Starting the Server After your mysqld program is built and any .my.cnf file is in place, you must initialize the databases (ONCE). bash$ mysql_install_db Then start the daemon with bash$ safe_mysql & After you start mysqld the first time, you then connect to it as "root" and GRANT permissions to other users. (Again, the MySQL root account has nothing to do with the *NIX root account.) Note You will need to start the daemons yourself. You can either ask your system administrator to add them to system startup files, or add a crontab entry that runs a script to check on these daemons and restart them if needed. Warning Do NOT run daemons or other services on a server without first consulting your system administrator! Daemons use up system resources and running one may be in violation of your terms of service for any machine on which you are a user! _________________________________________________________________2.6.3. Perl On the extremely rare chance that you don't have Perl on the machine, you will have to build the sources yourself. The following commands should get your system installed with your own personal version of Perl: bash$ wget http://perl.com/CPAN/src/stable.tar.gz bash$ tar zvxf stable.tar.gz bash$ cd perl-5.8.1 (or whatever the version of Perl is called) bash$ sh Configure -de -Dprefix=/home/foo/perl bash$ make && make test && make install Once you have Perl installed into a directory (probably in ~/perl/bin), you'll have to change the locations on the scripts, which is detailed later on this page. _________________________________________________________________2.6.4. Perl Modules Installing the Perl modules as a non-root user is probably the hardest part of the process. There are two different methods: a completely independant Perl with its own modules, or personal modules using the current (root installed) version of Perl. The independant method takes up quite a bit of disk space, but is less complex, while the mixed method only uses as much space as the modules themselves, but takes more work to setup. _________________________________________________________________2.6.4.1. The Independant Method The independant method requires that you install your own personal version of Perl, as detailed in the previous section. Once installed, you can start the CPAN shell with the following command: bash$ /home/foo/perl/bin/perl -MCPAN -e 'shell' And then: cpan> install Bundle::Bugzilla With this method, module installation will usually go a lot smoother, but if you have any hang-ups, you can consult the next section. _________________________________________________________________2.6.4.2. The Mixed Method First, you'll need to configure CPAN to install modules in your home directory. The CPAN FAQ says the following on this issue:5) I am not root, how can I install a module in a personal directory? You will most probably like something like this: o conf makepl_arg "LIB=~/myperl/lib \ INSTALLMAN1DIR=~/myperl/man/man1 \ INSTALLMAN3DIR=~/myperl/man/man3" install Sybase::Sybperl You can make this setting permanent like all "o conf" settings with "o conf commit". You will have to add ~/myperl/man to the MANPATH environment variable and also tell your Perl programs to look into ~/myperl/lib, e.g. by including use lib "$ENV{HOME}/myperl/lib"; or setting the PERL5LIB environment variable. Another thing you should bear in mind is th
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -