Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Fix cycle error during the destroy phase when we change workers order #1043

Conversation

barryib
Copy link
Member

@barryib barryib commented Oct 8, 2020

PR o'clock

Description

When we change workers order (remove the first worker group by example) all workers groups should be destroyed and recreated. This is done correctly for workers ASG, LT and LC, but not their dependencies like random and instance profiles.

Error: Cycle: module.eks.aws_launch_template.workers_launch_template[1] (destroy), module.eks.random_pet.workers_launch_template[1] (destroy), module.eks.aws_launch_template.workers_launch_template[0] (destroy deposed c013c2bc), module.eks.aws_iam_instance_profile.workers_launch_template[1] (destroy), module.eks.aws_launch_template.workers_launch_template[0], module.eks.random_pet.workers_launch_template[0], module.eks.aws_autoscaling_group.workers_launch_template[0], module.eks.aws_autoscaling_group.workers_launch_template[0] (destroy deposed d3ef3123), module.eks.random_pet.workers_launch_template[0] (destroy deposed cd8e2227)

Resolves #993

NOTES: Keep in mind that changing the order of workers group is a destructive operation. All workers group are destroyed and recreated. If you want to do this safely, you should move then in state with terraform state mv until we manage workers groups as maps.

Checklist

@barryib barryib merged commit c75fbb0 into terraform-aws-modules:master Oct 12, 2020
@barryib barryib deleted the tba/fix-cycle-error-during-destroy branch October 12, 2020 19:50
barryib added a commit to Polyconseil/terraform-aws-eks that referenced this pull request Oct 25, 2020
…order (terraform-aws-modules#1043)

NOTES: Keep in mind that changing the order of workers group is a destructive operation. All workers group are destroyed and recreated. If you want to do this safely, you should move then in state with `terraform state mv` until we manage workers groups as maps.
@github-actions
Copy link

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 17, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cycle when removing first item of worker_groups_launch_template list
2 participants