How to deploy Frappe on a production server using a non-default port (e.g., 8080)?

How can I deploy Frappe on a production server using a non-default port (e.g., 8080) instead of the default port 80?

Hi,

Use the below command to set different port:

bench set-nginx-port sitename 8080

Thanks,

Divyesh Mangroliya

Thanks, @mangroliya. I have already tried this command before from Setup Multitenancy but it doesn’t work! Is there something else I’m missing maybe? I want to run two frappe apps in production one is already using port 80, and I want another one to use port 8080.

Hi,

Please follow the Port Based Multitenancy and not the DNS based.

Port based multitenancy

You can create a new site and make run it on a different port (while the first one runs on port 80).

  • Switch off DNS based multitenancy (once)bench config dns_multitenant off
  • Create a new sitebench new-site site2name
  • Set portbench set-nginx-port site2name 82
  • Re generate nginx configbench setup nginx
  • Reload nginxsudo service nginx reload

Thanks,

Divyesh M.

@mangroliya The frappe apps are installed in two different benches, one bench is already running on port 80.

Hi,

Please go through this thread for your scenario: Multi Bench Setup with DNS based multitenancy at Production Server. How To? - Install / Update / Setup - Frappe Forum

Thanks,

Divyesh Mangroliya