cloud-nuke
cloud-nuke copied to clipboard
Support wait for dependent resources
Example: we use Terraform to create a EBS-Instance and three ElPs and connect them. cloud-nuke now runs into an issue: the EIPs can not be deleted while the EBS instance still exists, because EIPs can not be deleted while they are assigned. Even running cloud-nuke twice in a row (we are trying to use it to automatically reset an account regularly) does not solve this problem, because the EBS-instance requires time to shut down - more time than cloud-nuke running twice.
Would cloud-nuke considering such dependencies be something that could be added in the future? Since EBS-removal is already supported by cloud-nuke, how did you deal with such cases?
EBS instance? Do you mean an EC2 Instance? An EBS Volume? An EC2 Instance with EBS Volumes?
I mean an EBS application or environment. Theoretically the same can apply to EC2, but EIPs and S3 buckets are directly created from EBS, so that the problem appears more in the context of EBS.
It's more a general problem; it's also why Terraform waits while resources are destroyed, for example.
Sorry for the long delay. Got pulled away to focus on other things.
I mean an EBS application or environment.
Sorry, still not following. By EBS, do you mean Elastic Beanstalk? Or Elastic Block Store?
@naumannt do you still need any help here?
I meant Elastic Beanstalk Environment, yes.
This was a while ago, so I don't know if there was any changes regarding dependency resolution, and I didn't use Cloudnuke i quite a while.
Hey @naumannt, we are trying to be aware of the dependency between resources during the nuking operations. There are some resources that has logic to wait for certain resources to be deleted.
Since this issue has not been active for almost 2 years, will close this issue for now.