How to install InvoicePlane on Ubuntu 18.04

Jack Wallen tells you how to install the open source invoicing solution, InvoicePlane.

Image: Jack Wallen

If you're looking for a self-hosted invoicing system for your one-man shop or small-to-medium-sized business, you can always turn to open source. Why? Because there are many solutions that perfectly meet this need. Such a solution is InvoicePlane. This particular take on the invoicing platform allows you to manage quotes, invoices, clients, and payments. The software is free and not too challenging to set up.

I want to walk you through the process of installing InvoicePlan on Ubuntu 18.04.

What you need

I will assume you already have Ubuntu 18.04 up and running, and you have access to an account with sudo privileges. With that said, let's install.

SEE: Glossary: Hybrid cloud (Tech Pro Research)

Installing the necessary dependencies

The first thing you must do is take care of installing the necessary dependencies. The first thing we'll do is install the LAMP server. This can be done with the following command:

sudo apt-get install lamp-server^ 

This will install all of the components for your LAMP server.

Next we need to take care of the PHP pieces. Since mcrypt is no longer available to install from any repository, we must install it manually. Issue the following commands:

sudo apt-get -y install gcc make autoconf libc-dev pkg-config
sudo apt-get -y install php7.2-dev
sudo apt-get -y install libmcrypt-dev
sudo pecl install mcrypt-1.0.1

You will then need to add the following to /etc/php/7.2/apache2/php.ini:

Save and close that file. Now install the remaining PHP dependencies with the command:

sudo apt-get install php7.2 libapache2-mod-php7.2 php7.2-common php7.2-mbstring php7.2-xmlrpc php7.2-soap php7.2-gd php7.2-xml php7.2-intl php7.2-mysql wget unzip php7.2-cli php7.2-zip php7.2-curl -y

Next the php.ini file needs to be further edited to reflect the following changes:

memory_limit = 256M
upload_max_filesize = 128M
max_execution_time = 360
date.timezone = TIMEZONE

Where TIMEZONE is your actual timezone.

Start and enable Apache and MySQL

Both Apache and MySQL need to be started and enabled. This is done with the following commands:

sudo systemctl start apache2
sudo systemctl enable apache2
sudo systemctl start mysql
sudo systemctl enable mysql

Securing and configuring the database

If, during that installation, you are not prompted to configure a MySQL root user password, you can take care of that with the command:

sudo mysql_secure_installation

You will be prompted to set a root user password and take care of a few other security options. Once that is done, let's create the database and a user. Issue the command:

mysql -u root -p

Type the MySQL root user password. At the MySQL prompt, issue the commands:

CREATE DATABASE invplane_db;
CREATE USER 'invplane'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON invplane_db.* TO 'invplane'@'localhost';

Download InvoicePlane

To download the InvoicePlane package, issue the command:

wget -c -O

Unzip the downloaded folder with the command:

unzip v1.5.9

Move and rename the newly created ip directory with the command:

sudo mv ip /var/www/html/invoiceplane

Rename a couple of necessary files with the commands:

cd /var/www/html/invoiceplane
sudo cp ipconfig.php.example ipconfig.php
sudo cp htaccess .htaccess

Give the InvoicePlane directory the necessary permissions with the commands:

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

Configure Apache

Create a new configuration file for InvoicePlane with the command:

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

In that newly created file, add the following:

<VirtualHost *:80>
     DocumentRoot /var/www/html/invoiceplane

     <Directory /var/www/html/invoiceplane/>
          Options +FollowSymlinks
          AllowOverride All
          Require all granted

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


Make sure to customize that to suit your needs (such as the ServerAdmin, ServeName, and ServerAlias directives). Save and close that file. Enable the site (and rewrite module) with the commands:

sudo a2ensite invoiceplane.conf
sudo a2enmod rewrite

Restart Apache with the command:

sudo systemctl restart apache2

Complete the installation

Now you can point your browser to http://SERVER_IP/invoiceplane (Where SERVER_IP is the IP address of your server). At the resulting window (Figure A), click Setup.

Figure A

Figure A

You are ready to complete the InvoicePlane installation.

At this point it's just a matter of:

  • Selecting your language
  • Configuring the database details
  • Creating a user account

And that's it. You should now find yourself at the InvoicePlane main window, where you can begin to configure your company and start using this open source invoicing platform.

Also See

About Jack Wallen

Jack Wallen is an award-winning writer for TechRepublic and He’s an avid promoter of open source and the voice of The Android Expert. For more news about Jack Wallen, visit his website

Editor's Picks

Free Newsletters, In your Inbox