All Collections Clusters & Servers What are clusters in Hatchbox?

What are clusters in Hatchbox?

Clusters are a group of servers with responsibilities

Updated

Hatchbox groups your servers together in "clusters". Each server in the cluster is assigned roles to keep track of it's responsibilities. This enables Hatchbox to automatically assign firewall rules, add/remove IPs from load balancers, etc.

Let's look at a production cluster of 5 servers:

  1. Load balancer server
  2. Web server
  3. Web server
  4. Background worker server
  5. Postgres server

With this cluster, our load balancer knows to forward HTTP requests to the web servers. Our web and background worker servers are the only ones the application code needs to be deployed to. The Postgres server needs to allow access from the web and background worker servers from their private IPs.

If we add a new web server to the cluster, it will be automatically added to the load balancer's list of upstreams and added to the firewall rules on the Postgres server.