UbuntuUbuntu Based

How To Install SolidInvoice on Ubuntu 22.04 LTS

Install SolidInvoice on Ubuntu 22.04

In this tutorial, we will show you how to install SolidInvoice on Ubuntu 22.04 LTS. For those of you who didn’t know, SolidInvoice is a powerful, free, and open-source invoicing application designed to streamline the billing process for freelancers and small businesses. With its user-friendly interface and comprehensive set of features, SolidInvoice simplifies the creation, management, and tracking of invoices, estimates, and expenses.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of the SolidInvoice open-source invoicing application on Ubuntu 22.04 (Jammy Jellyfish). You can follow the same instructions for Ubuntu 22.04 and any other Debian-based distribution like Linux Mint, Elementary OS, Pop!_OS, and more as well.

Prerequisites

  • A server running one of the following operating systems: Ubuntu 22.04, 20.04, and any other Debian-based distribution like Linux Mint.
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • An active internet connection. You’ll need an internet connection to download the necessary packages and dependencies.
  • A non-root sudo user or access to the root user. We recommend acting as a non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.

Install SolidInvoice on Ubuntu 22.04 LTS Jammy Jellyfish

Step 1. To begin the installation process, it is essential to update your Ubuntu system to the latest available packages. This ensures that you have access to the most recent security patches, bug fixes, and compatibility updates. Open a terminal and execute the following commands:

sudo apt update
sudo apt upgrade

Step 2. Installing Apache Web Server.

The first step in setting up SolidInvoice is to install the Apache web server. Apache will handle the HTTP requests and serve the SolidInvoice application to users. To install Apache, follow these steps:

sudo apt install apache2

Once the installation is complete, allow HTTP and HTTPS traffic through the firewall using the following commands:

sudo ufw allow 'Apache'
sudo ufw allow 'Apache Secure'

Step 3. Installing MySQL Database Server.

SolidInvoice requires a database to store its data, and we will use MySQL for this purpose. To install and configure MySQL, follow these steps:

sudo apt install mysql-server

After the installation is complete, run the MySQL secure installation script to set up a strong root password and improve the security of your MySQL installation:

sudo mysql_secure_installation

Next, create a new MySQL database and user for SolidInvoice:

sudo mysql
CREATE DATABASE solidinvoice;
CREATE USER 'solidinvoice'@'localhost' IDENTIFIED BY 'your_strong_password';
GRANT ALL PRIVILEGES ON solidinvoice.* TO 'solidinvoice'@'localhost';
FLUSH PRIVILEGES;

Step 4. Installing PHP and Required Extensions.

SolidInvoice is built using PHP, so we need to install PHP and its required extensions. For this tutorial, we will use PHP 8.1 To install PHP and the necessary extensions, follow these steps:

sudo add-apt-repository ppa:ondrej/php

Update the package list and install PHP 8.1 along with the required extensions:

sudo apt update
sudo apt install php8.1 libapache2-mod-ph8.1 php8.1-mysql php8.1-curl php8.1-json php8.1-cgi php8.1-xsl php8.1-intl php8.1-mbstring php8.1-zip php8.1-xml php8.1-gd

Restart Apache for the changes to take effect:

sudo systemctl restart apache2

To verify that PHP is working correctly, create a phpinfo.php file in the Apache web root directory:

echo "<?php phpinfo(); ?>" | sudo tee /var/www/html/phpinfo.php

Visit http://your_server_ip/phpinfo.php in a web browser. You should see the PHP configuration page displaying the installed version and extensions.

Step 5. Installing SolidInvoice on Ubuntu 22.04.

Now download the latest SolidInvoice release from the official GitHub repository:

wget https://github.com/SolidInvoice/SolidInvoice/releases/download/2.2.5/SolidInvoice-2.2.5.zip

Extract the downloaded archive to the Apache web root directory:

sudo unzip SolidInvoice-2.2.5.zip -d /var/www/html/

Set the appropriate file and directory permissions for SolidInvoice:

sudo chown -R www-data:www-data /var/www/html/SolidInvoice-2.2.5/
sudo chmod -R 755 /var/www/html/SolidInvoice-2.2.5/

Step 6. Configure Apache.

Create a new Apache virtual host configuration file for SolidInvoice:

sudo nano /etc/apache2/sites-available/solidinvoice.conf

Add the following content to the file, replacing your_domain with your actual domain name:

<VirtualHost *:80>
ServerName your_domain
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html/SolidInvoice-2.2.5/public

<Directory /var/www/html/SolidInvoice-2.2.5/public>
AllowOverride All
Require all granted
</Directory>

ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

Save the file and exit the editor, then enable the SolidInvoice virtual host and disable the default one:

sudo a2ensite solidinvoice.conf
sudo a2dissite 000-default.conf

Restart Apache to load the new virtual host configuration:

sudo systemctl restart apache2

Step 7. Configure SSL/HTTPS.

To secure your SolidInvoice installation and protect sensitive data, it is highly recommended to configure SSL/HTTPS. We will use the Let’s Encrypt Certbot client to obtain and configure a free SSL certificate. Follow these steps:

sudo apt install certbot python3-certbot-apache

Obtain and configure an SSL certificate for your SolidInvoice domain:

sudo certbot --apache -d your_domain

Replace your_domain with your actual domain name. Follow the prompts to provide an email address and agree to the Let’s Encrypt terms of service.

Step 8. Accessing SolidInvoice Web UI.

Access the SolidInvoice web installer by visiting https://your_domain in a web browser. Follow the setup wizard to configure the application.

During the installation process, provide the MySQL database details you created earlier (database name, username, and password).

After completing the installation, log in to the SolidInvoice dashboard using the credentials you set up during the installation process.

Install SolidInvoice on Ubuntu 22.04

Congratulations! You have successfully installed SolidInvoice. Thanks for using this tutorial for installing the SolidInvoice open-source invoicing application on Ubuntu 22.04 LTS Jammy Jellyfish system. For additional help or useful information, we recommend you check the SolidInvoice website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

r00t

r00t is a seasoned Linux system administrator with a wealth of experience in the field. Known for his contributions to idroot.us, r00t has authored numerous tutorials and guides, helping users navigate the complexities of Linux systems. His expertise spans across various Linux distributions, including Ubuntu, CentOS, and Debian. r00t's work is characterized by his ability to simplify complex concepts, making Linux more accessible to users of all skill levels. His dedication to the Linux community and his commitment to sharing knowledge makes him a respected figure in the field.
Back to top button