When you launch clusters through Banzai Cloud Pipeline, the platform creates several resources on your cloud provider. When you decide to terminate a cluster, Pipeline deletes these resources for you. This page describes the termination process and what you can do if it fails.

Delete cluster 🔗︎

To delete a cluster using the Pipeline web interface, complete the following steps.

CAUTION:

Do not delete the cluster directly from your cloud provider, as that prevents Pipeline from properly deleting the related resources from the provider. If you have already deleted the cluster from your provider, use the forced termination flow as described below.
  1. Log in to the Pipeline web interface, and click Main Menu > Cluster Management.

  2. Find the cluster you want to delete in the list, then click Delete cluster.

  3. To confirm that you really want to delete the cluster, enter the name of the cluster into the NAME OF THE CLUSTER field.

    Delete cluster
  4. Click DELETE. Pipeline starts to delete the cluster using the graceful termination flow.

    Note: If deleting the cluster fails for some reason, repeat this procedure. If it still fails, repeat this procedure again, but clear the Graceful delete option to start the forced termination flow.

  5. If you have used the forced termination flow, check your cloud provider console to verify that everything was deleted successfully.

Delete cluster from the CLI 🔗︎

CAUTION:

Do not delete the cluster directly from your cloud provider, as that prevents Pipeline from properly deleting the related resources from the provider. If you have already deleted the cluster from your provider, use the forced termination flow as described below.
  1. Log in to Pipeline.

  2. To terminate a cluster named my-cluster, run:

    banzai cluster delete my-cluster
    

    Pipeline starts to delete the cluster using the graceful termination flow.

    Note: If deleting the cluster fails for some reason, repeat this command. If it still fails, run the following command to start the forced termination flow. banzai cluster delete --force my-cluster

  3. If you have used the forced termination flow, check your cloud provider console to verify that everything was deleted successfully.

Graceful termination flow 🔗︎

The regular termination flow basically does the opposite as the create flow, in a reverse order. First, it removes every Helm release and Pipeline-installed resource from the cluster, then it deletes the related cloud provider resources.

Normally every resource related to the cluster gets deleted, including attached volumes and load balancers created during the lifecycle of the cluster.

If the termination process fails, it stops and the cluster gets into an error state. This usually happens if the cloud provider rejects deleting a resource (for whatever reason). In that case, you can try rerunning the graceful termination flow (it usually solves the problem) or you can use the forced termination flow.

Forced termination flow 🔗︎

Compared to the graceful flow, forced termination does not stop on errors. It goes through the whole process and deletes everything it can. Therefore it’s recommended as a last resort if nothing else works.

CAUTION:

Always check manually that everything was successfully deleted on the cloud provider console after a forced termination.