kubernetes-sigs / cluster-api-provider-ibmcloud

Cluster API Provider for IBM Cloud
https://cluster-api-ibmcloud.sigs.k8s.io
Apache License 2.0
60 stars 76 forks source link

VPC cluster deletion fails with delete load balancer pool member #1784

Closed Amulyam24 closed 1 month ago

Amulyam24 commented 1 month ago

/kind bug /area provider/ibmcloud

What steps did you take and what happened: In a case where VPC instance creation fails and we proceed to delete the cluster, it fails with the following error while deleting the load balancer pool member as instance ID is empty.

"Reconciler error" err=<
[manager]   failed to delete loadBalancer pool member: getInstanceOptions failed validation:
[manager]   Key: 'GetInstanceOptions.ID' Error:Field validation for 'ID' failed on the 'ne' tag
[manager]  > controller="ibmvpcmachine" controllerGroup="infrastructure.cluster.x-k8s.io" controllerKind="IBMVPCMachine" IBMVPCMachine="default/amulya-test-vpc-control-plane-8nmfz" namespace="default" name="amulya-test-vpc-control-plane-8nmfz" 

What did you expect to happen: VPC cluster to be deleted successfully.

Anything else you would like to add: [Miscellaneous information that will assist in solving the issue.]

Environment: