Metadata Inheritance
Metadata now inherits from base components, just like vars and settings.
The Problem
When managing infrastructure at scale, you want to enforce consistent governance policies across your components. Pin all instances to the same component version. Lock critical infrastructure to prevent accidental changes. Use standardized workspace naming patterns. Document component ownership.
But before this release, metadata didn't inherit from base components. Even though you could inherit vars and settings, you had to copy-paste metadata configuration to every derived component:
# You defined governance once...
vpc/defaults:
metadata:
type: abstract
component: vpc/v2 # Pin to version
locked: true
terraform_workspace_pattern: "{tenant}-{environment}-{stage}"
custom:
description: "Virtual Private Cloud network configuration"
owner: "platform-team"
# ...but had to repeat EVERYTHING for each instance
vpc/primary:
metadata:
inherits: [vpc/defaults]
component: vpc/v2 # Repeated
locked: true # Repeated
terraform_workspace_pattern: "{tenant}-{environment}-{stage}" # Repeated
custom: # Repeated
description: "Virtual Private Cloud network configuration" # Repeated
owner: "platform-team" # Repeated
vpc/secondary:
metadata:
inherits: [vpc/defaults]
component: vpc/v2 # Repeated again
locked: true # Repeated again
terraform_workspace_pattern: "{tenant}-{environment}-{stage}" # Repeated again
custom: # Repeated again
description: "Virtual Private Cloud network configuration" # Repeated again
owner: "platform-team" # Repeated again
The biggest pain? When upgrading to vpc/v3, you had to update the component version in every single instance. Miss one, and you'd have components running different versions with no indication why.
The Solution
Now it just works:
vpc/defaults:
metadata:
type: abstract
component: vpc/v2 # Define version once
locked: true
terraform_workspace_pattern: "{tenant}-{environment}-{stage}"
custom:
description: "Virtual Private Cloud network configuration"
owner: "platform-team"
vpc/primary:
metadata:
inherits: [vpc/defaults]
# component, locked, terraform_workspace_pattern, and custom are all inherited
vpc/secondary:
metadata:
inherits: [vpc/defaults]
# All governance settings inherited - no repetition needed
Want to upgrade to vpc/v3? Change it once in vpc/defaults, and all instances inherit the new version automatically.
Two fields are excluded from inheritance:
metadata.inherits- defines the inheritance relationship itselfmetadata.type- component type is per-component (e.g.,abstractshouldn't propagate to derived components)
Configuration
Metadata inheritance is now enabled by default. If this causes issues with existing configurations, you can disable it:
# atmos.yaml
stacks:
inherit:
metadata: false
See the inheritance documentation for details.
