How to Install ERPNext on Ubuntu 20.04

Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
Subscribe
"The best Linux newsletter on the web"

This post is about How to Install ERPNext on Ubuntu 20.04

ERPNext is the open-source ERP software built by frappe technologies. It has other functions that organizations need, such as Accounting, HR, Sales, Purchase, Inventory, etc. ERPNext is built on top of the frappe framework that allows for rapid application development, and it’s built using python and MariaDB. It is released under GNU/GPL 3. It has a user-friendly interface, and you can easily customize the software according to your need.

Prerequisites

Requirements

  • Ubuntu 20.04
  • Python 3.6+
  • Node.js 12
  • Redis 5
  • MariaDB 10.3.x / Postgres 9.5.x
  • yarn 1.12+
  • pip 20+
  • wkhtmltopdf (version 0.12.5 with patched qt)
  • cron
  • NGINX

Step 1: Install and Update the BaseOS for the software.

Step 2: Install Python Tools & wkhtmltopdf

$ sudo ap$ sudo apt -y install vim libffi-dev python3-pip python3-dev python3-testresources libssl-dev wkhtmltopdft -y install vim libffi-dev python3-pip python3-dev python3-testresources libssl-dev wkhtmltopdf

Step 3: Install Curl, Redis and Node.Js

$ sudo curl --silent --location https://deb.nodesource.com/setup_14.x | sudo bash -
$ curl -sL https://dl.yarnpkg.com/debian/pubkey.gpg | gpg --dearmor | sudo tee /usr/share/keyrings/yarnkey.gpg >/dev/null
$ echo "deb [signed-by=/usr/share/keyrings/yarnkey.gpg] https://dl.yarnpkg.com/debian stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
$ sudo apt-get update && sudo apt-get install yarn
$ sudo apt -y install gcc g++ make nodejs redis-server

Step 4: Install Nginx web server and MariaDB Database server

$ sudo apt -y install nginx
$ sudo apt install mariadb-server
$ sudo mysql -u root
USE mysql;
UPDATE user SET plugin='mysql_native_password' WHERE User='root';
UPDATE user SET authentication_string=password('your_password') WHERE user='root';
FLUSH PRIVILEGES;
EXIT;
sudo nano /etc/mysql/mariadb.conf.d/50-server.cnf

Download the file from following link and open in notepad

https://github.com/faheemkhan5/ERPNext-MariaDB-FIle.git

copy all content from the downloaded file and paste into the file opened in nano

$ sudo systemctl restart mariadb

Step 5:

A bench is a tool used to install and manage ERPNext on your Ubuntu system. We will create a user that will run the ERPNext system, then configure the system.

$ sudo useradd -m -s /bin/bash erpnext
$ sudo passwd erpnext
$ sudo usermod -aG sudo erpnext

Update Path

$ sudo su - erpnext
$ tee -a ~/.bashrc<<EOF
PATH=\$PATH:~/.local/bin/
EOF
$ source ~/.bashrc

Create a directory for ERPNext setup and give erpnext user read and write permissions to the directory

$ sudo mkdir /opt/bench
$ sudo chown -R erpnext /opt/bench

Switch to erpnext user and install the application

$ sudo su - erpnext
$ cd /opt/bench

Install frappe bench and git

$ sudo apt install git
$ sudo pip3 install frappe-bench

 initialize the bench directory with frappe framework installed. Make sure you are still inside the /opt/bench directory

$ bench init erpnext

Create a new Frappe site

$ cd erpnext
$ bench new-site erp.abcxyz.com

Step 6: Download ERPNext application from git

$ bench get-app branch version-13 erpnext https://github.com/frappe/erpnext

Step 7: Install ERPNext on Ubuntu 20.04

$ bench --site erp.abcxyz.com install-app erpnext

Step 8: Start ERPNext

$ bench start

Map your server IP in your localhost hosts file

Run notepad as Administrator
clicl file -> open -> windows -> system32 -> drivers -> etc

“your server ip” erp.abcxyz.com

save

open your WebBroser and type

http://erp.abcxyz.com:8000

username: Administrator and your password during installation
complete the steps according to your requirements
Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
Subscribe
"The best Linux newsletter on the web"
Fazal
Fazal
Solution Architect. passionate about exploring, deploying, and writing about new technologies related to systems, networks, cloud, and microservices.

4 COMMENTS

  1. Followed the steps
    Run my server which is runing on http://192.168.1.113:8000/
    When I open it on the browser I get 404 Not Found response
    Can you help please?

  2. Run notepad as Administrator
    clicl file -> open -> windows -> system32 -> drivers -> etc

    192.168.1.113 erp.abc.com

    also make sure you have configured your frappe site correctly

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest articles

Join us on Facebook