Skip to content
Concepts

The Kuppit model

Projects, environments, resources and deployments, and how they connect into one application graph.

Kuppit describes an application as a graph, not as a list of cloud primitives. Four nouns carry the whole model, and everything in the dashboard is one of them.

Project  acme
│
├── Production
│     ├── web         Web service
│     │     ▲
│     │     │ DATABASE_URL
│     │     │
│     └── database    PostgreSQL
│
└── pr-42             Preview
      └── web         Web service

Projects

A project is a GitHub repository connected to Kuppit. It names the application, remembers which installation grants access to the repository, and holds the environments.

A project does not deploy, does not hold variables, does not own a hostname and does not produce logs. Those all belong to resources inside an environment. Deleting a project tears down every environment in it.

Environments

An environment is one complete instance of the application: its own resources, its own variables, its own hostnames. Every project has a Production environment, and can have others:

TypeCreatedRemoved
ProductionWith the project.With the project. It cannot be deleted on its own.
PreviewAutomatically, when a pull request opens. Named pr-<number>.Automatically, when the pull request closes.
CustomBy you, for staging, QA or anything else long-lived.By you.

Environments are isolated from each other by default. A service in staging cannot see production's database unless you deliberately share it, and a variable set in one environment does not exist in another.

When you create an environment from an existing one, you decide per resource how the new environment gets its copy:

ChoiceWhat you get
Create newAn isolated resource of the same shape, with no data in it.
ShareNo new infrastructure. Both environments read and write the same data.
CloneAn isolated copy of the data at creation. Changes afterwards are independent.
Don't includeThe new environment has no resource for this.

Sharing is the one choice that breaks isolation, and the dashboard marks a shared resource with a Shared badge wherever it appears.

Resources

A resource is something your application runs or depends on. Kuppit has two kinds today:

  • A web service is built from the repository and deployed. It has deployments, logs, variables and domains.
  • A PostgreSQL database is provisioned and managed by Kuppit. It exposes its connection details as variables that services can reference.

Resources live inside an environment and are named within it. The name is how other resources address it: a database named database is referenced as database.DATABASE_URL.

Deployments

A deployment turns one commit into a running revision of one web service. It moves through Queued, Building and Deploying to Live, or stops as Failed or Cancelled. A new deployment replaces the previous one only once it is healthy; until then the previous revision keeps serving.

A deployment is immutable. It records the commit, the build settings and the variables it was prepared with, so a Previous deployment can be rolled back to exactly as it was.

The application graph

Resources connect to each other through variable references. When a service's variable points at a variable exposed by another resource, that is an edge in the graph:

database ── DATABASE_URL ──▶ web

Read it as: the web service references a variable exposed by database. The arrow follows the data. The database provides the value; the service consumes it. Kuppit resolves every reference when it prepares a deployment, from the target's current state, so a service is always connected to the resource as it is now.

The environment's Overview draws this graph. Everything else in the model follows from it:

  • Isolation is a property of the graph having no edges between environments.
  • Sharing is an edge that crosses one.
  • Cloning copies a node without copying its edges' targets.
  • A generated variable is a value a node exposes for others to reference.

Read on in Environment variables for how references are written and resolved.

Was this page helpful?