Railway

Deploy ERPNext | Full ERP Stack | Open Source Odoo Alternative

Self Host ERPNext on Railway: accounting, inventory, HR, CRM

Deploy ERPNext | Full ERP Stack | Open Source Odoo Alternative

DBs

Just deployed

/var/lib/mysql

RedisCache

redis:8.2.1

Just deployed

/data

RedisQueue

redis:8.2.1

Just deployed

/data

/home/frappe/bench/sites

ERPNext logo

Deploy and Host ERPNext on Railway

Deploy on Railway

ERPNext is a 100% open-source ERP from Frappe Technologies — accounting, inventory, manufacturing, CRM, HR, projects — released under AGPLv3 as a free alternative to Odoo, NetSuite, and SAP Business One. Self-hosting ERPNext is usually painful: the official Frappe Docker stack runs 7+ containers sharing a sites volume, which is why most teams pay for Frappe Cloud.

Deploy ERPNext on Railway in one click. The template bundles supervisor, gunicorn, three worker types, the scheduler, socketio, and nginx into one container, leaving MariaDB and two Redis instances as separate services. Self-host ERPNext with real workers — no compose orchestration.

ERPNext Railway architecture

Getting Started with ERPNext on Railway

First boot takes 3–5 minutes: the entrypoint waits for MariaDB (a 90×2s mysqladmin ping loop), runs bench new-site, installs the frappe and erpnext apps, and enables the scheduler. Once the service goes green, open the *.up.railway.app domain and log in as Administrator with the value from RFP_SITE_ADMIN_PASSWORD. Frappe's Welcome wizard asks for language, country, currency, fiscal year, and company name — about two minutes. Add a custom domain whenever you like; the site is pinned to frontend with use_dns_multitenant=0, so the hostname can change without renaming the site.

ERPNext dashboard screenshot

About Hosting ERPNext on Railway

ERPNext is the flagship app on Frappe — a metadata-driven Python + JS platform.

  • Double-entry accounting, multi-currency, multi-company
  • Manufacturing (BOM, work orders, MRP), inventory, quality
  • CRM, selling, buying, projects, HR, payroll, assets
  • REST/GraphQL APIs, custom doctypes and scripts
  • AGPLv3 — no per-user fees

Architecture: ERPNext container (supervisor → gunicorn + 3 workers + scheduler + socketio + nginx) → MariaDB 10.6 → RedisCache → RedisQueue (RQ + socketio collapsed).

Why Deploy ERPNext on Railway

Railway removes the Frappe Docker pain — no compose file, no manual MariaDB tuning.

  • One-click deploy, all four services wired via ${{Service.VAR}} references
  • Private networking between ERPNext, MariaDB, and Redis (no public DB ports)
  • Persistent volume on /home/frappe/bench/sites survives redeploys
  • 8 GB memory cap pre-set for the Frappe container
  • Free HTTPS domain; add a custom domain whenever you want

Common Use Cases for Self-Hosted ERPNext

  • Manufacturers running BOMs, work orders, stock
  • Distributors needing multi-warehouse inventory plus accounting
  • Service businesses billing projects and timesheets with full GL
  • Schools, clinics, non-profits using Frappe Education / Healthcare

Dependencies for the ERPNext Railway Template

  • ERPNextgithub.com/praveen-ks-2001/erpnext-railway, based on frappe/bench:v5.22.9 (derived from pipech/erpnext-docker-debian)
  • MariaDBmariadb:10.6 (Railway's MySQL image overridden; Frappe needs MariaDB)
  • RedisCache — Railway-managed Redis for Frappe's cache backend
  • RedisQueue — Railway-managed Redis, shared by RQ workers and socketio pub/sub

Environment Variables Reference

VariableServicePurpose
RFP_SITE_ADMIN_PASSWORDERPNextBootstrap Administrator password (first boot only)
RFP_DOMAIN_NAMEERPNextFrappe site name, pinned to frontend
RFP_DB_HOST / RFP_DB_ROOT_PASSWORDERPNextMariaDB host + root password for bench new-site
RFP_REDIS_CACHE_URL / RFP_REDIS_QUEUE_URL / RFP_REDIS_SOCKETIO_URLERPNextCache, queue, and pub/sub Redis URLs
MYSQL_ROOT_PASSWORDMariaDBManaged by Railway's MySQL template

Deployment Dependencies for ERPNext on Railway

Hardware Requirements for Self-Hosting ERPNext

ResourceMinimumRecommended
CPU2 vCPU4 vCPU
RAM (ERPNext)4 GB8 GB (template default)
RAM (MariaDB)1 GB2 GB
Storage (sites volume)5 GB20 GB+
RuntimeDebian + Python 3.10Debian + Python 3.10

Frappe documents 4 GB minimum, 8 GB recommended; the template caps ERPNext at 8 GB.

Self-Hosting ERPNext Without This Template

Build the same image:

git clone https://github.com/praveen-ks-2001/erpnext-railway
cd erpnext-railway
docker build -t erpnext-railway .

Run it against MariaDB 10.6 and two Redis instances:

docker run -d --name erpnext \
  -e RFP_DOMAIN_NAME=frontend \
  -e RFP_SITE_ADMIN_PASSWORD=changeme \
  -e RFP_DB_HOST=mariadb -e RFP_DB_ROOT_PASSWORD=rootpw \
  -e RFP_REDIS_CACHE_URL=redis://cache:6379 \
  -e RFP_REDIS_QUEUE_URL=redis://queue:6379 \
  -e RFP_REDIS_SOCKETIO_URL=redis://queue:6379 \
  -p 80:80 -v sites:/home/frappe/bench/sites erpnext-railway

How Much Does ERPNext Cost to Self-Host?

ERPNext is free under AGPLv3 — no per-user fees, seat caps, or paywalls. The only cost on Railway is infrastructure for the four containers. Frappe sells managed Frappe Cloud and paid support, both optional.

ERPNext vs Odoo vs NetSuite

ToolLicenseBest for
ERPNextAGPLv3 (free)SMB / mid-market, full source access
Odoo CommunityLGPLv3 (open-core)Teams happy paying for Enterprise modules
NetSuiteProprietary SaaSEnterprises with deep budgets
SAP Business OneProprietaryMid-market manufacturing

ERPNext is the strongest fully-open option — every module, including manufacturing, ships in community.

FAQ

What is ERPNext and why self-host it on Railway? Open-source ERP from Frappe Technologies. Self-hosting on Railway gives you data ownership and predictable infra cost without running Docker Compose.

What does this Railway template deploy? Four services: ERPNext app (supervisor + gunicorn + 3 workers + scheduler + socketio + nginx), MariaDB 10.6, two Redis.

Why does this template need MariaDB instead of MySQL? Frappe's migrations and full-text search depend on MariaDB features. MySQL 8/9 are not supported — the template ships mariadb:10.6 deliberately.

How do I reset the ERPNext Administrator password after first boot? RFP_SITE_ADMIN_PASSWORD is read only by bench new-site on first deploy. To change it later, shell into ERPNext and run bench --site frontend set-admin-password .

Can I add a custom domain to my self-hosted ERPNext on Railway? Yes. The site is pinned to frontend with use_dns_multitenant=0, so Frappe ignores the Host header — no bench rename-site required.

Can I install other Frappe apps like HRMS on Railway? Yes — fork the repo, add bench get-app lines to the Dockerfile, redeploy.


Template Content

More templates in this category

View Template
Foundry Virtual Tabletop
A Self-Hosted & Modern Roleplaying Platform

Lucas
View Template
Letta Code Remote
Run a Letta Code agent 24/7. No inbound ports, just deploy.

Letta
View Template
(v1) Simple Medusa Backend
Deploy an ecommerce backend and admin using Medusa

Shahed Nasser