How to Install Webtrees on OpenSUSE Latest
Introduction
Webtrees is a free and open-source genealogy software that allows families to create, maintain, and share their family trees online. In this tutorial, we will guide you on how to install Webtrees on OpenSUSE latest.
Prerequisites
Before we begin with the installation, we need to ensure that our system meets the following prerequisites:
- A server running OpenSUSE latest
- An Apache web server installed and enabled
- A MySQL or MariaDB database server installed and running
- PHP version 7.2 or higher installed and enabled with required extensions
Step 1: Download Webtrees
The first step is to download the latest version of Webtrees from the official website. You can download it using the following command:
wget https://github.com/fisharebest/webtrees/releases/download/2.0.4/webtrees-2.0.4.zip
Step 2: Install Required Dependencies
To run Webtrees, we need to install some required dependencies. Run the following command to install these dependencies:
sudo zypper install unzip php-mbstring php-gd php-curl php-xml php-mysqlnd
Step 3: Extract Webtrees Archive
Extract the downloaded Webtrees archive to Apache document root directory /srv/www/htdocs/ using the following command:
sudo unzip webtrees-2.0.4.zip -d /srv/www/htdocs/
Step 4: Set Correct Permissions
Make sure the Apache web server user www owns the webtrees directory and its files:
sudo chown -R www:www /srv/www/htdocs/webtrees
Step 5: Create a Database And User
Create a new database and user for Webtrees using the following commands:
CREATE DATABASE webtrees;
CREATE USER 'wtuser'@'localhost' IDENTIFIED BY 'wtpassword';
GRANT ALL PRIVILEGES ON webtrees.* TO 'wtuser'@'localhost';
FLUSH PRIVILEGES;
Note: Replace wtuser and wtpassword with your desired username and password.
Step 6: Configuration
Now, create a new configuration file for Webtrees using the following command:
sudo cp /srv/www/htdocs/webtrees/data/config/config.dist.php /srv/www/htdocs/webtrees/data/config/config.php
Edit the config.php file and replace the following configuration values with your MySQL or MariaDB database values:
define('WT_DB_HOST', 'localhost');
define('WT_DB_NAME', 'webtrees');
define('WT_DB_USER', 'wtuser');
define('WT_DB_PASSWORD', 'wtpassword');
Step 7: Configure Apache
Create a new virtual host configuration file for Apache using the following command:
sudo nano /etc/apache2/conf.d/webtrees.conf
Add the following lines to the file:
<VirtualHost *:80>
ServerName example.com
DocumentRoot /srv/www/htdocs/webtrees
<Directory /srv/www/htdocs/webtrees/>
Options FollowSymLinks MultiViews
AllowOverride All
Require all granted
</Directory>
ErrorLog /var/log/apache2/webtrees_error.log
CustomLog /var/log/apache2/webtrees_access.log combined
</VirtualHost>
Save and close the file.
Step 8: Restart Apache
Finally, restart the Apache web server to apply the changes:
sudo systemctl restart apache2
Access Webtrees
Open your browser and enter your configured ServerName. You will see the Webtrees homepage.
Conclusion
In this tutorial, we have shown you how to install Webtrees on OpenSUSE latest. You can now start creating your family trees and sharing them with your loved ones.