Skip to main content
Open console

Shapes

How many machines an environment runs on, what each one does, and what each layout asks of your application.

5 min read

A shape is how many machines an environment runs on and what each of them does. The configurator calls it topology.

Shape What it is Machines
Flexible infrastructure Your machines, your layout. Move any service onto a machine of its own whenever you want. 1
Dedicated A balancer, two or more web servers, and every other service on a machine of its own. 4

Flexible infrastructure

You draw the layout, from one machine up.

Every service starts on the web server. Leave them there and one machine runs everything: the web server, the application, the database and the cache, with files on local disk and no private network. Every staging and development environment runs this way, whatever production runs.

Move any service onto a machine of its own, or onto one shared with a couple of others. The platform creates a private network as soon as there is a second machine. For example: the database on its own for its IO, Solr and the broker sharing a machine, a worker keeping the site's CPU free. Each machine is named for what it carries, so the server list reads db, search-queue, worker-cache.

You do not change shape to grow. The same shape covers a site on one machine and a site on six, so spreading out later means moving a service.

Give the database a machine of its own when:

  • It competes with the site for memory. This usually shows as the site getting slower under load while neither machine looks busy on its own.
  • It has run out of room. The database always stays on the machine, so more disk means a machine of its own, or a bigger one.
Part Rule
Varnish On the web server, or on a machine of its own, where it shares with nothing.
Worker machine Never on the web server.
Uptime promise Any, on any number of machines.
Entry-line machines Allowed. Premium support is not sold with one.

On a shared plan there is nothing to draw. Your site runs on one machine that belongs to the platform, with other sites on it. A worker or an extra is a second machine and needs a dedicated plan. See Plans.

Dedicated

Every service (the database, the cache, search, the broker) runs on a machine of its own, behind a load balancer that is always there. Nothing is shared and there is nothing to draw.

Part Rule
Web servers Two web servers at minimum, so the tier survives losing one.
The only numbers you set How many web servers beyond that, and how many workers.
Database backups Nightly, as everywhere. Every four hours is an add-on on either shape.
Entry-line machines Not offered.
Machines From four up: the balancer, two web servers and the database. In practice five, because a Drupal stack also wants a cache.

If you want a machine per service and nothing more, Flexible draws exactly that and costs less. Dedicated adds a web tier that keeps answering when a machine goes away.

Two web servers is a migration, not a checkbox. Settle it before you buy this shape. Three things stop being local; the platform handles one and the other two are yours:

  • Files. Handled for you. One web machine holds the files directory and exports it to the others over the private network, so an upload landing on web-1 is there on web-2. A bucket is still the better answer once the uploads are large.
  • Sessions. A session stored on local disk logs the visitor out every time the balancer sends them to the other machine. Keep sessions in the database or the cache. Drupal and WordPress already do; Valkey is not required. If the application cannot move them, turn on Keep each visitor on one web machine in the environment's proxy options. A visitor then loses their session when their machine goes down or restarts.
  • Scheduled work. Only one machine runs your schedule, so nothing runs twice. A job that assumes it is on the machine that took the upload, or writes to a local path, will not find what it expects.

Sessions and scheduled work are work in your application, not a setting here. Every framework we support can do both.

A machine for background work

On Flexible and Dedicated you can add a worker machine. It is optional: without one, your schedule and any long-running processes run on the web machine, alongside the site.

Add one when background work slows the site. A nightly import that pins a CPU for twenty minutes competes with your visitors' requests, and the symptom is a slow site, not a slow import.

With a worker machine, every process you declared under workers moves there. The schedule under cron stays on the web machine, where the site's files are. See Workers.

It is a machine, and it is priced as one. You choose its size like any other, and it appears as its own line on the quote. A worker doing occasional overnight work does not need what your web machine needs.

Without a worker machine, long-running workers are bounded rather than refused: one declared worker per machine that can run one. That is each worker machine where you have them, each web machine otherwise. A deploy that declares more than there is room for says so. Then add a worker machine, add another web server, or fold the work into a worker you already have. See vallic.yaml.

Changing shape

You cannot move an existing project between Flexible and Dedicated, or between plans: either would move your data between machines. Adding capacity within a shape, bigger machines or more disk, is always available.

Within Flexible there is one exception: the environment's Resources tab can give the database, cache, search or queue a machine of its own after the site is built, and bring cache, search or queue back. It shows what will move and what it costs in downtime before anything happens. See Upgrades.

Within Dedicated, the same tab changes how many web servers and workers there are:

  • Every web server is the same size, and a new one is built at the size of the others.
  • A new one is sent your live code before it takes any traffic, so adding one never serves errors.
  • Fewer takes away the highest-numbered machines, after the load balancer has stopped sending them requests.
  • The subscription follows the machines either way.
  • To change their size, resize any one of them on the machines page. The others in the role move with it, one at a time.

Next

Need a hand?

Open a ticket from Support in the console. We answer on the ticket.

Open the console How support works