Undeploy (remove) stacks within the given command path.
Takomo also removes stacks that depend on the stacks within the command path, even if they are outside the given command path. Takomo arranges the stacks in removal order by stack dependencies, ensuring that it removes the stacks in the correct order and in parallel when possible.
tkm stacks undeploy [command-path] \[--ignore-dependencies] \[--interactive|-i]
Command path to select which stacks to undeploy.
Optional, by default, Takomo undeploys all stacks.
In addition to the common options, this command has the following options.
Ignore stack dependencies. By default, when a stack is removed, its dependants are removed first, and then the stack itself. In some exceptional cases, you might want to remove just one stack and skip its dependants.
Bear in mind that this option is supported only when exactly one stack is removed. Ignoring dependants may lead into unexpected results, so you should use this option only in exceptional circumstances.
Choose the command path using autocompleting search.
These are the minimum IAM permissions required to run this command.
# Minimum permissions. Additional permissions are needed to actually# remove the resources defined in CloudFormation templates.Statement:- Sid: StacksEffect: AllowAction:- cloudformation:DescribeStackEvents- cloudformation:DeleteStack- cloudformation:DescribeStacksResource: "*"# IAM permissions needed only if command roles are used# Specify resource to restrict access to specific roles.- Sid: IAMEffect: AllowAction:- sts:AssumeRoleResource: "*"
Undeploy all stacks:
tkm stacks undeploy
Undeploy stacks within the given command path:
tkm stacks undeploy /dev
Undeploy only /dev/vpc.yml stack and its dependants:
tkm stacks undeploy /dev/vpc.yml
The region part must be specified if the stack has more than one region and you want to undeploy it from only one region.
tkm stacks undeploy /dev/vpc.yml/eu-west-1
Undeploy exactly one stack and skip its dependants:
tkm stacks undeploy /cloudtrail.yml --ignore-dependencies