Frappe Production Setup – DNS Loads HTML Only, Missing CSS/JS Bundles (404 Errors)

We are facing an issue while setting up ERPNext/Frappe in production on our server.

Here’s our setup:

  • DNS → Firewall IP → Local Server (where we are installing Frappe in production)
  • We followed the official production setup process.
  • On the local server, the bench is working perfectly.
  • We are running Frappe in production mode using Supervisor.
  • DNS is pointing correctly to our server (verified by toggling maintenance mode).

The Problem

When accessing the site via DNS, the HTML loads, but no CSS or JS bundles load.
On both DNS and IP access, we only see the raw HTML without styling or interactivity.


Browser Console Errors

plaintext

CopyEdit

Download the React DevTools for a better development experience: https://fb.me/react-devtools
contentscript.bundle.js:1 Teflon Content Script injected

/assets/frappe/dist/css/website.bundle.N3UF3RRC.css:1 GET https://erp.parkmont.co.in/assets/frappe/dist/css/website.bundle.N3UF3RRC.css net::ERR_ABORTED 404
/assets/frappe/dist/css/login.bundle.5UZ7UMY6.css:1 GET https://erp.parkmont.co.in/assets/frappe/dist/css/login.bundle.5UZ7UMY6.css 404
/assets/frappe/dist/js/frappe-web.bundle.2Y7H3RYT.js:1 GET https://erp.parkmont.co.in/assets/frappe/dist/js/frappe-web.bundle.2Y7H3RYT.js 404
/assets/frappe/images/frappe-framework-logo.svg:1 GET https://erp.parkmont.co.in/assets/frappe/images/frappe-framework-logo.svg 404
Uncaught ReferenceError: $ is not defined
    at login.reset_sections ((index):3187:3)
    at login.login ((index):3200:8)
    at login.route ((index):3182:14)

Observations

  • The site loads fine locally via http://localhost (with CSS/JS).
  • Through DNS, only HTML loads – all asset requests return 404.
  • Nginx seems not to be serving the /assets path properly or the build files are missing.

Any help or guidance would be greatly appreciated. We’ve been stuck on this for 3 days now.

Have you tired the bench build and check the error log in ngnix

Hi

If assets are not loading … check /var/log/nginx/error.log… you would see permission error ??

If its a permission denied issue then the below should resolve it in most cases.

sudo chmod o+rx /home/frappe (or whatever is your home folder)