atmos stack set
Set a component-relative value for a component in a stack. Atmos uses provenance to find the manifest file that defines the effective value and edits that file in place, preserving comments, anchors/aliases, Atmos YAML functions, and Go templates.
info
atmos stack set is an alias for atmos stack config set, the canonical form.
Usage
atmos stack set <path> <value> -s <stack> -c <component> [--type <type>] [--file <manifest>]
Examples
# Set the value where it currently resolves from.
atmos stack set vars.region us-west-2 -s plat-ue2-prod -c vpc
# Typed value.
atmos stack set settings.spacelift.workspace_enabled true --type=bool -s plat-ue2-prod -c vpc
# Edit (or create the key in) a specific manifest.
atmos stack set vars.new_flag yes --file stacks/deploy/prod.yaml -s plat-ue2-prod -c vpc
Arguments
<path>(required)- Component-relative dot-notation path (e.g.
vars.region). <value>(required)- The value to set, interpreted according to
--type.
Flags
--stack/-s(string, required)- The stack name.
--component/-c(string, required)- The component name.
--type(string, defaultstring)- How to interpret
<value>:string,int,bool,float,null, oryaml(raw literal). --file(string)- Edit this manifest explicitly instead of resolving via provenance. Required when the value is not yet defined anywhere; can also be used to create new keys.
note
Edits that would alter or expand a YAML anchor or alias are rejected to avoid silently mutating shared data, as are multi-document manifests and manifests that define the same anchor name more than once. Comments, anchors, indentation width, and line endings (CRLF/LF) are preserved, but blank lines between entries are dropped and non-indented sequence styles are normalized when a file is edited.