Serve a site via IP along with the domain

Hello,

I need to serve my Frappe site via IP and port, alongside the real domain name.

  1. I used bench setup add-domain MY-PRIVATE-IP; nginx.conf re-generated.
  2. gunicorn is listening on port 8000, default.
  3. Production setup, multi-tenancy is ON hostname-based is ON, but we have only one site.

Accessing http://MY-PRIVATE-IP:8000 won’t reach Frappe.

If it matters: the server is in a private network, requires VPN to access. On my Windows machine, I mapped a dummy domain to the IP on the hosts file and it worked fine, but I need to serve the site via the IP as well.

Your advice is highly appreciated.

I think you don’t need dns based multitenancy. DNS server on the computers will resolve given name to IP. For port to work dns based multitenancy must be off.

So if you want to access your instance via http://logedo.com:8001 first logedo.com must resolve to your instance IP.

1 Like