Skip to main content

Multi-environment SaaS

Blueprint
One design, three environments, one compliance story

The most common shape: your application, the data services it needs, a gateway in front of it, and the operational surface that lets you answer a customer's security questionnaire without a project.

The shape​

LayerComponents
ApplicationYour code, built by the platform from your repository — one component per service
DataRelational database with a dedicated database per service, cache, object storage, message broker
EdgeGateway with routes, TLS, rate limiting and authentication mode per route
IdentityIdentity provider with a client per application that needs a login
ObservabilityMetrics, dashboards, alerts, logs and tracing, wired from the links
ScaleAutoscaling driven by queue depth, a metrics query or a log query
RecoveryBackup from the database to object storage, with schedule and retention on the link
AssuranceStack agent, admission policy, and the compliance frameworks you are asked about

Environments are values, not branches​

THE DESIGNone graphDEVELOPMENTsmallown domainSTAGINGlike productionown domainPRODUCTIONsized · scaledown domainrendered once per environment
One design, rendered once per environment. Each environment differs only in its values — sizes, replicas, domain.

The base design is rendered once. Each environment is an overlay carrying only what differs — replica counts, resource sizes, the domain, and which optional components exist at all.

That has three consequences worth stating plainly:

1Staging is really staging

It is the same graph, so a problem that only appears in production is a value difference you can name, not an unexplained environment difference.

2Promotion is a value change

Not a merge between diverging trees.

3A new environment is cheap

Duplicating the stack gives you a complete second system, relations included.

Several applications, one repository​

Application components do not each need their own repository. Several can live in one repository, each in its own folder with its own container build, named after the component. That is the cheaper default and needs no new credentials.

The alternative — a repository per application — is equally supported. The model will ask you which, rather than assuming.

The security questionnaire​

This is where the operational surface pays for itself. The questions a customer asks are the questions the stack agent already answers with evidence:

They askYou run
Is traffic between services restricted?Network policy scan — every declared link, both directions, with real probes
Who has administrative access?RBAC scan — bindings, privileged holders, wildcards
Are secrets encrypted?Secrets scan, plus the repository encryption model
Do you enforce workload security policy?Admission policy scan, including over-enforcement
Are backups tested?Backup scan — and the verdict distinguishes "completed" from "actually holds data"
Are you PCI or ISO aligned?The framework scan, with per-control evidence and the signed position on every gap
How do you know this is still true?The attestation chain, the delta classification and the scan schedule

→ Compliance automation · Evidence and drift