Loading…
Loading…
The blocks are the ones bench generates for these sites. Add one, or switch routing mode.
Sites on this bench
bench config dns_multitenant on bench new-site beta.example.com bench --site beta.example.com install-app erpnext bench setup nginx bench setup reload-nginx
nginx server blocks bench writes
listen 80
server_name acme.example.com beta.example.com
X-Frappe-Site-Name $host
Each site, its own database
Send a request
→ beta.example.com nginx matched the name, and passed $host as X-Frappe-Site-Name.
Database names are random, set when each site is created — the ones shown are examples.
Shared
The code, the apps you have fetched, the workers, Redis and the server. One bench update upgrades every site.
Separate
Each site’s database, files, users and settings — and which apps are installed on it.
Watch out
Every site upgrades together, and one heavy site slows the rest. Back up and restore each site on its own.
Yes, in two ways. One bench can hold many sites, each with its own database and users. Or one site can hold several companies, sharing users and masters. Which fits depends on how separate they must be.
A bench setting. When it is on, nginx tells sites apart by the name in the address, so every site can use ports 80 and 443. When it is off, each site gets its own port.
Run bench new-site with the new name, install the apps on it, then regenerate and reload the nginx configuration with bench setup nginx and bench setup reload-nginx.
Yes. The code is the bench’s, so updating the bench upgrades every site on it. Apps, though, are installed site by site.
bench setup lets-encrypt only works with dns_multitenant on. Turn it on, regenerate nginx, and make sure the domain points at the server.
We set up multi-site benches, or a multi-company ERPNext on one site — whichever fits — and keep every site upgraded and backed up. Talk to a consultant.
or write to info@acube.co
Kochi (Kadavanthra & Infopark) · Thiruvananthapuram · across India & overseas · In business since 2011