How to Install Mautic Marketing Automation Tool in Linux - Barcode Brand Consulting

How to Install Mautic Marketing Automation Tool in Linux

Grow Your Business By Leveraging Marketing Automation and AI | UpCity
August 26, 2020
5 Ways Marketing Automation is Evolving
August 26, 2020

How to Install Mautic Marketing Automation Tool in Linux

Mautic is a free open source, web-based and leading marketing automation tool that enables you to understand, manage, and grow your business or organization conveniently. It is highly customizable and extensible, to meet your business requirements.

It is still a very young project at the time of writing this article. It runs on most standard hosting environments and it is easy to install and setup. In this article, we will show how to install Mautic in Linux distributions.

Step 1: Install LEMP Stack in Linux

1. First, install LEMP stack (Nginx, MySQL or MariaDB and PHP) on your respective Linux distributions using the default package manager as shown.

Install LEMP on Debian and Ubuntu

Install LEMP on CentOS and RHEL

2. Once LEMP stack installed, you can start Nginx, PHP-fpm and MariaDB services, enable them and check if these services are up and running.

3. If your system has a firewall enabled by default, you need to open the port 80 in the firewall to allow client requests to the Nginx web server, as follows.

Step 2: Secure MariaDB Server and Create Mautic Database

4. By default, the MariaDB database installation is unsecure. To secure it, run the security script which comes with the binary package.

You will be asked to set a root password, remove anonymous users, disable root login remotely and remove the test database. After creating a root password, and answer yes/y to the rest of the questions.

5. Then log in to MariaDB database and create a database for Mautic.

Run these commands to create the database; use your own values here, and set a more secure password in a production environment.

Step 3: Download Mautic Files to Nginx Web Server

6. The latest release (version 2.16 at the time of this writing) of Mautic is available as a zip file, go to the download page, then provide your details in a short form and click on the download link.

7. Once you have downloaded, create a directory for storing the Mautic files for your site under your web server document root (this will be your application base or root directory).

Then unzip the archive file into your application root directory, and define correct permissions on the root directory and mautic files, as follows:

Step 4: Configure PHP and Nginx Server Block for Mautic

8. In this step, you need to configure the date.timezone setting in your PHP configuration, set it to a value applicable to your current location (for example “Africa/Kampala”), as shown in the screenshot.

Set Timezone in PHP Settings

9. Then restart the php-fpm service to effect the changes.

10. Next, create and configure an Nginx server block for serving the Mautic application, under /etc/nginx/conf.d/.

Add the following configuration in the above file, for the purpose of this guide, we will use a dummy domain called mautic.tecmint.lan (you may use your own test or full registered domain):

11. Save the file and then restart the Nginx web server for the above changes to work.

Step 5: Complete Mautic Installation via Web installer

12. Because we are using a dummy domain, we need to set up a local DNS using the hosts’ file (/etc/hosts), for it to work, as shown in the following screenshot.

Setup Local DNS in Linux

13. Then use the following URL to access the Mautic web installer. It will, first of all, check your system to ensure that all requirements are met (if you see any error or warning, correct them before proceeding, especially in a production environment).

If your environment is ready for mautic, click on the Next Step.

Mautic Installation Setup Wizard

14. Next, provide your database server connection parameters and click on the Next Step. The installer will be verifying the connection settings and create the database.

Mautic Database Details

Note at this stage, if you get a “504 Gateway Timeout Error”, it is because Nginx is failing to get any response from PHP-FPM while the database is being created; it times out.

To fix this, add the following highlighted line in the PHP location block inside the mautic server block configuration file /etc/nginx/conf.d/mautic.conf.

Fix Timeout Error in Nginx

15. Then restart Nginx and php-fpm services for the recent change to take effect.

16. Next, create your mautic application admin user account and click Next Step.

Create Mautic Admin Account

17. As a final step, configure your email services as shown in the following screenshot and click Next Step.

Configure Mautic Mail

17. Now log into your mautic application using the admin account credentials.

Mautic Admin Login

18. At this point, you can start automating your business marketing from the admin control panel, as shown in the following screenshot.

Mautic Admin Control Panel Dashboard

Mautic is a leading marketing automation platform. It is still a very young project and many features, that you can think of, are yet to be added. If you encountered any issues while installing it, let us know via the feedback form below. Also share your thoughts about it with us, especially concerning features you would like it to have.

Leave a Reply

Your email address will not be published. Required fields are marked *

Call Now!
WeCreativez WhatsApp Support
Our customer support team is here to answer your questions. We shall be happy to assist you :)
👋 Howdy...