How to Install Webtrees on Fedora CoreOS Latest

Webtrees is an open-source genealogy website software with powerful features and intuitive user interface. In this tutorial, we will guide you through the process of installing Webtrees on the latest version of Fedora CoreOS.

Prerequisites

  1. Access to a terminal or command-line interface.
  2. An active Fedora CoreOS installation with root privileges.
  3. A domain name or IP address through which you can access your server.

Step 1: Install Docker

Before we begin with the installation of Webtrees, we need to make sure that Docker is installed on our system.

To install Docker, follow these steps:

  1. Access the terminal or command-line interface and log in as a root user.

  2. Run the following command to install Docker:

    $ rpm-ostree install docker
    
  3. After the installation is complete, start the Docker service by running:

    $ systemctl enable --now docker.service
    

Step 2: Create a Docker Network

We need to create a Docker network to ensure that the Webtrees container can communicate with the database container.

To create a Docker network, follow these steps:

  1. Run the following command to create a Docker network:

    $ docker network create webtreenet
    

Step 3: Install MariaDB

Webtrees requires a database backend to store and retrieve data. In this tutorial, we will be using MariaDB.

To install MariaDB, follow these steps:

  1. Run the following command to create a MariaDB container:

    $ docker run --name mariadb -e MYSQL_ROOT_PASSWORD=<ENTER_PASSWORD_HERE> -v mariadbstorage:/var/lib/mysql --network webtreenet -d mariadb:latest
    

    Replace <ENTER_PASSWORD_HERE> with a strong root password for your MariaDB instance.

  2. Verify that the MariaDB container is running by running:

    $ docker ps
    
  3. Log in to MariaDB using the following command:

    $ docker exec -it mariadb mysql -p
    

    Enter the root password when prompted.

  4. Create a new database and user for Webtrees:

    CREATE DATABASE webtreedb;
    GRANT ALL PRIVILEGES ON webtreedb.* TO 'webtreeuser'@'%' IDENTIFIED BY '<ENTER_PASSWORD_HERE>';
    FLUSH PRIVILEGES;
    

    Replace <ENTER_PASSWORD_HERE> with a strong password for the Webtrees database user.

Step 4: Install Webtrees

Now that Docker, the Docker network, and the MariaDB backend are set up, we can proceed with the installation of Webtrees.

To install Webtrees, follow these steps:

  1. Run the following command to create a Webtrees container:

    $ docker run -d --name webtrees -p 80:80 -e WT_DB_PASSWORD=<ENTER_PASSWORD_HERE> -e WT_DB_DATABASE=webtreedb -e WT_DB_HOST=mariadb -e WT_DB_USERNAME=webtreeuser --network webtreenet webtrees/webtrees:latest
    

    Replace <ENTER_PASSWORD_HERE> with the password you set for the Webtrees database user.

  2. Verify that the Webtrees container is running by running:

    $ docker ps
    
  3. Access your server using your domain name or IP address, followed by /setup.php. For example, http://example.com/setup.php.

  4. Follow the on-screen instructions to set up your Webtrees website.

  5. After the setup is complete, remove the setup.php file by running:

    $ docker exec -it webtrees rm /var/www/html/setup.php
    

Conclusion

Congratulations! You have successfully installed Webtrees on Fedora CoreOS using Docker containers. You are now ready to start building your family tree and exploring the many features offered by Webtrees.

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!