awslabs / crossplane-on-eks

Crossplane bespoke composition blueprints for AWS resources
Apache License 2.0
307 stars 109 forks source link

[Bug]: destroy.sh doesn't run cleanly #167

Closed askulkarni2 closed 3 weeks ago

askulkarni2 commented 5 months ago

Welcome to AWS Blueprints for Crossplane!

AWS Blueprints for Crossplane Release version

v0.1.0

What is your environment, configuration and the example used?

https://github.com/awslabs/crossplane-on-eks/tree/main/bootstrap/terraform

What did you do and What did you see instead?

Running destroy.sh to cleanup and running into this.

╷
│ Error: deleting EC2 Subnet (subnet-0d0c1d9a1782ecc16): DependencyViolation: The subnet 'subnet-0d0c1d9a1782ecc16' has dependencies and cannot be deleted.
│       status code: 400, request id: 15d530b6-9c74-43b5-928f-7854b6defd37
│ 
│ 
╵
╷
│ Error: deleting EC2 Subnet (subnet-0513e2114646f177b): DependencyViolation: The subnet 'subnet-0513e2114646f177b' has dependencies and cannot be deleted.
│       status code: 400, request id: 436038fd-1dc8-4927-89d9-ecdfe017dd25
│ 
│ 
╵
╷
│ Error: deleting EC2 Subnet (subnet-0e349deeef2ad5678): DependencyViolation: The subnet 'subnet-0e349deeef2ad5678' has dependencies and cannot be deleted.
│       status code: 400, request id: 1b9038f6-6f50-495f-bfea-9ec2fdb57c64
│ 
│ 
╵

This happening due to NLBs not getting cleaned up prior to VPC destroy.

Additional Information

No response

edgarsilva948 commented 3 weeks ago

@candonov I think we can close this.

candonov commented 3 weeks ago

@candonov I think we can close this.

@edgarsilva948 Did you do anything to fix it or did it self resolve?

edgarsilva948 commented 3 weeks ago

the VPC deletion may fail because of the issue that I've documented here in the FAQ. I think we can improve the destroy doc tho.