Skip to content

Commit

Permalink
fix: diconnect before delete
Browse files Browse the repository at this point in the history
  • Loading branch information
aldor007 committed Nov 14, 2023
1 parent bc4fd95 commit a600f6f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion castai/cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ func resourceCastaiClusterDelete(ctx context.Context, data *schema.ResourceData,
return retry.RetryableError(fmt.Errorf("triggered cluster deletion"))
}

if agentStatus == sdk.ClusterAgentStatusDisconnected {
if agentStatus == sdk.ClusterAgentStatusDisconnected || clusterStatus == sdk.ClusterStatusDeleted {
return triggerDelete()
}

Expand Down

0 comments on commit a600f6f

Please sign in to comment.