atmos icon indicating copy to clipboard operation
atmos copied to clipboard

atmos terraform apply Option to Apply All Components in a Stack in Order

Open aclarke822 opened this issue 6 months ago • 1 comments
trafficstars

Describe the Feature

When applying a particular stack, instead of requiring a specific component be specified, have an option to apply all components in order.

Something like: atmos terraform apply -s STACK_NAME -a

Order could be determined by order of import or order of depends_on.

Expected Behavior

atmos terraform apply -s STACK_NAME -a

Applies all components in a stack in order such as order of import or depends_on.

Use Case

Allows zero configuration in order to apply stacks with varying components. Otherwise, a workflow would need to be defined for every different combination of components used in a stack in order to fully deploy a stack with 1 command.

Describe Ideal Solution

Ideal solution is to have 1 command per stack that could deploy the entire stack without any additional configuration.

Alternatives Considered

Many and complex Atmos workflows or other scripting solutions.

Additional Context

No response

aclarke822 avatar May 08 '25 21:05 aclarke822

This is planned, and @aknysh started some work on this. Unfortunately, we don't have an ETA.

osterman avatar May 09 '25 14:05 osterman

Is it correct to say that v1.181.0 implements this feature and resolves this issue? https://github.com/cloudposse/atmos/releases/tag/v1.181.0

I just gave it a cursory test (1.182.0) and it seems like it does the job (via workflow): atmos terraform plan --all --auto-generate-backend-file true atmos terraform deploy --all --auto-generate-backend-file true

aclarke822 avatar Jul 08 '25 18:07 aclarke822

It partially implemented it. Unfortunately, the dependency order applies are only with the --affected argument.

The ability to apply --all components in order is not yet implemented, but is planned. We just wanted to keep the pull request smaller.

osterman avatar Jul 08 '25 18:07 osterman

Quick question: When you say order is not yet implemented, I'm assuming you mean dependency order is not implemented for the --all option correct? Is the order for --all currently import order?

aclarke822 avatar Jul 08 '25 18:07 aclarke822