Favas Sidhik

0 %
FAVAS SIDHIK
IT Consultant | IT Infrastructure & Managed Services Expert | ERP & Digital Transformation Specialist
  • Residence:
    United Arab Emirates
  • City:
    Dubai
  • Origin
    India
  • Age:
    42
Areas of Expertise
  • IT Project Management
  • IT Infrastructure Management
  • System Administration
  • Network Administration
  • Cloud Management
  • Endpoint Management
Technically Expertised in
Windows Servers & Client OS
Linux Servers & Client OS
Fortinet Firewalls
VMWare
Hyper-V
Azure
Micrsoft 365
Google Workspace
SCCM, Intune , RMM (Datto, Pulseway)

Frappe ERPNext On-prem server installation in less than 20 steps

November 4, 2025

How to Set Up a Frappe ERPNext Site for Production: Step-by-Step Guide

Deploying ERPNext in a production environment ensures stability, security, and performance for your business operations. This guide will walk you through setting up an ERPNext production server using Ubuntu, Nginx, Supervisor, and Let’s Encrypt SSL for security.


1. Prerequisites

Before starting, make sure you have:

RequirementDescription
OSUbuntu 22.04 LTS or 20.04 LTS (Recommended)
Server SpecsMinimum 4GB RAM, 2 vCPUs, 40GB SSD
AccessSSH root or sudo user
Domain Name(Optional but recommended for SSL)
Python VersionPython 3.10 or above
DatabaseMariaDB (Recommended)

2. Update and Install System Dependencies

 
sudo apt update && sudo apt upgrade -y sudo apt install git python3-dev python3-pip python3-venv \ software-properties-common mariadb-server mariadb-client \ redis-server nginx curl -y

3. Secure MariaDB Database

 
sudo mysql_secure_installation
  • Set root password → Yes

  • Remove anonymous users → Yes

  • Disallow remote root login → Yes

  • Remove test database → Yes


4. Setup ERPNext User (Non-Root)

 
sudo adduser frappe sudo usermod -aG sudo frappe su - frappe

5. Install Bench CLI (Frappe Framework)

 
pip3 install frappe-bench bench --version # To verify installation

6. Initialize a Bench Instance

 
bench init --frappe-branch version-15 frappe-bench cd frappe-bench

You can replace version-15 with your preferred branch like version-14, develop, etc.


7. Create a New ERPNext Site

 
bench new-site yoursite.domain.com

It will ask for:

  • MySQL root password

  • Admin (Administrator) password for ERPNext login


8. Download and Install ERPNext App

 
bench get-app --branch version-15 erpnext bench --site yoursite.domain.com install-app erpnext

9. Start Development Server (Test Run)

 
bench start

Open in browser:
➡️ http://your_server_ip:8000 or http://yoursite.domain.com:8000


10. Setup for Production

Install Supervisor & Nginx support:
 
sudo apt install supervisor -y bench setup production frappe # Replace 'frappe' with your Linux user if different

This automatically configures:
✔ Nginx
✔ Supervisor for background jobs
✔ Enabling ERPNext on boot

11. Enable HTTPS (SSL with Let’s Encrypt)

 
sudo bench setup lets-encrypt yoursite.domain.com

12. Useful Bench Commands

CommandDescription
bench restartRestart all services
bench updateUpdate ERPNext & dependencies
bench backupCreate system backup
bench setup nginxRegenerate and apply Nginx config
sudo supervisorctl statusCheck worker status

13. Configure Firewall (Optional but Recommended)

 
sudo ufw allow OpenSSH sudo ufw allow http sudo ufw allow https sudo ufw enable

14. Access Your ERPNext Site

✅ Login URL: https://yoursite.domain.com
✅ Default user: Administrator
✅ Login with the password set in Step 7.


15. Bonus Tips

  • Schedule automatic daily backups to remote storage.

  • Enable SMTP for outgoing emails.

  • Install apps like HRMS, POSAwesome, Payments, etc.:

     
    bench get-app hrms bench --site yoursite install-app hrms
  • Use fail2ban and SSH keys for security.


Conclusion

By following these steps, you’ve successfully deployed ERPNext in a secure, scalable, and production-ready environment. This setup is ideal for real businesses, hosting on VPS/cloud, and supporting multiple users.

Posted in Software Tutorials, TechnologyTags: