# Immutable Infrastructure

> An approach in which servers are replaced from a new image for every change, instead of being patched in place.

Record: `architecture:immutable-infrastructure`
Kind: approach
Layer: [Resource Core](https://banes-lab.com/records/layer/resource-core.md)
Severity: contextual
Scope: infrastructure, deployment, reproducibility
Canonical: https://banes-lab.com/ontology#architecture-immutable-infrastructure

Listed in [Architecture principles](https://banes-lab.com/api/records/architecture.md), after [Configuration Externalization](https://banes-lab.com/records/architecture/configuration-externalization.md) and before [Single Responsibility Principle (SRP)](https://banes-lab.com/records/architecture/single-responsibility.md).

## Repair

- Refactored by: Replace Instances from Immutable Images
- Detected by: SSH mutation of live instances
- Violated by: patching running servers in place
- Measured by: config drift across instances
- Enforced by: deployment review

## Requires

- [Infrastructure as Code](https://banes-lab.com/records/architecture/infrastructure-as-code.md)

## Reinforces

- [Environment Parity](https://banes-lab.com/records/architecture/environment-parity.md)
- [Reproducibility](https://banes-lab.com/records/architecture/reproducibility.md)

## Enables

- [Deterministic Redeploys](https://banes-lab.com/records/lexicon/deterministic-redeploys.md)
- [Instance Replacement over Mutation](https://banes-lab.com/records/lexicon/instance-replacement-over-mutation.md)

## Conflicts with

- [In-Place Server Mutation](https://banes-lab.com/records/lexicon/in-place-server-mutation.md)

## In tension with

- [Deploy Time](https://banes-lab.com/records/lexicon/deploy-time.md)

## Tensions

- [Immutable Infrastructure / Deploy Time](https://banes-lab.com/records/tension/deploy-time-immutable-infrastructure.md)

## Severity

- [contextual](https://banes-lab.com/records/vocabulary/severity-contextual.md)

## Category

- [Portability / Infrastructure / Deployment](https://banes-lab.com/records/architecture-category/portability-infrastructure-deployment.md)

## Linked from

- [Correctness / Determinism / Verification](https://banes-lab.com/ontology/principles/architecture-category-correctness-determinism-verification.md)
- [Portability / Infrastructure / Deployment](https://banes-lab.com/ontology/principles/architecture-category-portability-infrastructure-deployment.md)
- [Portability / Infrastructure / Deployment](https://banes-lab.com/ontology/lexicon/lexicon-category-portability-infrastructure-deployment.md)
- [Severity levels](https://banes-lab.com/ontology/schema/the-vocabulary-severity.md)
- [The resolutions](https://banes-lab.com/ontology/schema/the-resolutions.md)
