Bugzilla is a popular bug tracking system used by many organizations for software development. In this tutorial, we'll guide you through the steps to install Bugzilla on FreeBSD Latest.
Before we begin, ensure your FreeBSD system is up to date by running the following command:
sudo pkg update && sudo pkg upgrade
Next, we need to install some required packages that Bugzilla needs to function properly. Use the following command to install these packages:
sudo pkg install apache24 mysql57-server perl5 mod_php74 php74-mysqli php74-gd
Once the packages are installed, we need to configure MySQL. Use the following command to start the MySQL service:
sudo service mysql-server start
Then, run the following command to secure your MySQL installation:
sudo mysql_secure_installation
Follow the prompts and set a strong root password, then answer "Y" to the remaining questions.
Create a new user to run Bugzilla by running the following command:
sudo adduser -m bugzilla
Download the latest version of Bugzilla from https://www.bugzilla.org/download/ and extract the files to the "/usr/local/www/" directory using the following command:
sudo tar xvf bugzilla*.tar.gz -C /usr/local/www/
Next, we need to install the required Perl modules. Navigate to the Bugzilla directory and run the following command:
cd /usr/local/www/bugzilla-<version>/
sudo perl install-module.pl --all
Note: Replace <version>
with the version number of the Bugzilla you downloaded.
We need to configure Bugzilla before we can start using it. Navigate to the "conf" directory and copy "localconfig" file to "localconfig-orig":
cd /usr/local/www/bugzilla-<version>/conf/
sudo cp localconfig localconfig-orig
Then, edit "localconfig" file using your favorite text editor and set the following parameters:
$db_driver = 'mysql';
$db_host = 'localhost';
$db_name = 'bugs';
$db_user = 'bugs';
$db_pass = 'SecurePassword';
Replace "SecurePassword" with a strong password for your MySQL user.
Create a new MySQL database for Bugzilla by running the following commands:
sudo mysql -u root -p
CREATE DATABASE bugs;
CREATE USER 'bugs'@'localhost' IDENTIFIED BY 'SecurePassword';
GRANT ALL PRIVILEGES ON bugs.* to 'bugs'@'localhost';
FLUSH PRIVILEGES;
exit;
Set the correct file permissions on the Bugzilla directory to ensure it's accessible by the web server:
sudo chown -R www:www /usr/local/www/bugzilla-<version>/
sudo chmod -R 755 /usr/local/www/bugzilla-<version>/
Finally, we need to configure Apache to serve Bugzilla. Open the Apache configuration file in your favorite text editor and add the following lines:
<VirtualHost *:80>
ServerName bugzilla.example.com
DocumentRoot /usr/local/www/bugzilla-<version>/
AddHandler cgi-script .cgi
DirectoryIndex index.cgi
<Directory /usr/local/www/bugzilla-<version>>
Options +Indexes +ExecCGI
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
Note: Replace "bugzilla.example.com" with your server's domain name and "
Save the file and restart Apache to apply the changes:
sudo service apache24 restart
You can now access Bugzilla by navigating to "http://bugzilla.example.com" in your web browser. Follow the prompts to finish the installation and setup your Bugzilla instance.
Congratulations, you have successfully installed Bugzilla on FreeBSD Latest!
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!