Anahita is a platform that allows you to build social networking websites and online communities. In this tutorial, we will show you how to install Anahita on a Fedora Server Latest operating system.
Before starting the installation process, make sure to have the following prerequisites:
Before we start with the installation process, let's first update the system:
sudo dnf update -y
Anahita requires a web server and a database server to run. We will install Apache and MariaDB to meet this requirement:
sudo dnf install httpd mariadb-server -y
Once the installation is complete, start both services and enable them to start at boot:
sudo systemctl start httpd
sudo systemctl enable httpd
sudo systemctl start mariadb
sudo systemctl enable mariadb
Anahita is a PHP-based platform that requires PHP and some extensions to function correctly. We will install PHP and all necessary extensions using the following command:
sudo dnf install php php-mysqli php-pdo php-gd php-mbstring php-json php-xml -y
Next, configure PHP settings in the /etc/php.ini file:
sudo nano /etc/php.ini
Set the following values:
memory_limit = 256M
upload_max_filesize = 100M
post_max_size = 100M
max_execution_time = 360
Save and exit the file.
Before downloading Anahita, we need to install Git:
sudo dnf install git -y
Then, navigate to the /var/www/html directory where the Apache root directory is located:
cd /var/www/html
Clone the Anahita repository from Github:
sudo git clone https://github.com/anahitasocial/anahita.git
Change the ownership of the Anahita directory to Apache:
sudo chown -R apache:apache anahita
To access Anahita, we need to create a virtual host. Create a new configuration file for the Anahita virtual host:
sudo nano /etc/httpd/conf.d/anahita.conf
Add the following code in the file:
<VirtualHost *:80>
DocumentRoot /var/www/html/anahita
ServerName your-domain.com
<Directory /var/www/html/anahita>
AllowOverride All
</Directory>
ErrorLog /var/log/httpd/anahita-error.log
CustomLog /var/log/httpd/anahita-access.log combined
</VirtualHost>
Replace "your-domain.com" with your domain name or server IP address.
Save and exit the file.
We need to create a new MariaDB database and user for Anahita. Connect to the MariaDB server:
sudo mysql -u root
Create a new database:
CREATE DATABASE anahita;
Create a new database user:
CREATE USER 'anahitauser'@'localhost' IDENTIFIED BY 'your-password';
Grant all privileges to the user:
GRANT ALL PRIVILEGES ON anahita.* TO 'anahitauser'@'localhost';
Flush the privileges and exit the MariaDB shell:
FLUSH PRIVILEGES;
EXIT;
Now that everything is set up, we can proceed with the installation of Anahita. Open your web browser and navigate to your virtual host domain or IP.
Follow the instructions and fill in the required information such as database details, site name, and admin account credentials.
After completing the installation process, log in to the Anahita dashboard, and you're ready to start building your online community.
Congratulations! You have successfully installed Anahita on Fedora Server 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!