How to Install Firefly III on EndeavourOS Latest

Pre-requisites

  • A VPS with EndeavourOS latest installed
  • SSH access with sudo privileges
  • Your domain name pointed to your VPS IP (optional)

Step 1: Connect to your server

  • Open your terminal and connect to your server using SSH
    ssh user@server_ip_address
    
  • Run the following command to update your system and upgrade all the installed packages
    sudo pacman -Syu
    

Step 2: Install PHP and Additional Dependencies

  • Install PHP and required extensions

    sudo pacman -S php php-fpm php-gd php-intl php-mbstring php-pdo php-sqlite php-cgi
    
  • Install NGINX web server

    sudo pacman -S nginx
    
  • Start the NGINX service and enable it to start at boot time

    sudo systemctl start nginx
    sudo systemctl enable nginx
    

Step 3: Create an NGINX Configuration file for Firefly III

  • Navigate to the NGINX sites directory

    cd /etc/nginx/sites-available
    
  • Create a new file for Firefly III configuration

    sudo nano firefly.conf
    
  • Add the following content to the configuration file and replace example.com with your domain name (optional)

    server {
          listen 80;
          listen [::]:80;
    
          root /usr/share/webapps/firefly-iii/;
          index index.php index.html index.htm;
    
          server_name example.com;
    
          location / {
              try_files $uri $uri/ /index.php?$query_string;
          }
    
          location ~ \.php$ {
              fastcgi_pass unix:/run/php-fpm/php-fpm.sock;
              fastcgi_index index.php;
              include fastcgi.conf;
          }
      }
    
  • Save and exit the configuration file by pressing CTRL+X, then Y, and then ENTER.

Step 4: Download and Install Firefly III

  • Navigate to the web directory

    cd /usr/share/webapps/
    
  • Download Firefly III latest version from the official website

    sudo wget https://github.com/firefly-iii/firefly-iii/releases/download/5.5.8/firefly-iii-5.5.8.zip
    
  • Extract the downloaded file into the current directory

    sudo unzip firefly-iii-5.5.8.zip
    
  • Run the following command to change the permissions of Firefly III directory

    sudo chmod -R 755 firefly-iii
    

Step 5: Configure Firefly III

  • Navigate to the Firefly III directory

    cd firefly-iii
    
  • Copy the sample configuration file

    sudo cp .env.example .env
    
  • Edit the configuration file

    sudo nano .env
    
  • Change the following lines by updating with your sensitive information like database name, username, and password

      DB_DATABASE=firefly
      DB_USERNAME=root
      DB_PASSWORD=password
    
  • Save and exit the configuration file by pressing CTRL+X, then Y, and then ENTER.

Step 6: Create a database for Firefly III

  • Login into MariaDB

    sudo mysql -u root -p
    
  • Create a new database for Firefly III

    CREATE DATABASE firefly;
    
  • Create a new user for Firefly III

    CREATE USER 'firefly' IDENTIFIED BY 'password';
    
  • Grant the required privileges to the user

    GRANT ALL ON firefly.* TO 'firefly'@'localhost';
    
  • Exit MariaDB

    exit
    

Step 7: Run Firefly III Installation Wizard

  • Open your browser and navigate to http://your-server-ip/firefly-iii/public/install
  • Follow the installation wizard steps by accepting the license, checking for the requirements, and inserting your database and admin account information
  • After successful installation, you can access Firefly III by navigating to http://your-server-ip/firefly-iii/public in your browser

Congratulations! You have installed Firefly III on your EndeavourOS server. Now, you can manage your finances, keep track of your expenses, and plan your budget easily.