Fix aws cluster deleting
@@ -144,6 +144,10 @@ func (ac *AWSCluster) deleteEksClusterVpc(cfClient *cloudformation.CloudFormatio
stackId := resp.Stacks[0].StackId
+ _, err = cfClient.DeleteStack(&cloudformation.DeleteStackInput{
+ StackName: clusterStackName,
+ })
+ if err != nil {
_, err = cfClient.DeleteStack(&cloudformation.DeleteStackInput{
StackName: clusterStackName,
RetainResources: []*string{aws.String("Ipv6VPCCidrBlock")},
@@ -151,6 +155,7 @@ func (ac *AWSCluster) deleteEksClusterVpc(cfClient *cloudformation.CloudFormatio
if ac.checkDeferError(err) {
return
}
+ }
for {
resp, err := cfClient.DescribeStacks(&cloudformation.DescribeStacksInput{
