This topic describes how to delete extensions deployed in prior versions of Tanzu Kubernetes Grid, v1.3 or earlier. You can do this after you have installed the corresponding packages to the same cluster, for example you can delete a legacy Contour extension after deploying the Contour package using tanzu package install.

Note: If you are migrating extensions to packages, follow the deletion steps in Migrate Tanzu Kubernetes Grid Extensions to Packages instead of the procedures below to avoid data loss.

Prepare to Delete Extensions

  1. In a terminal, navigate to the folder that contains the unpacked Tanzu Kubernetes Grid extension manifest files, tkg-extensions-v1.3.0+vmware.1/extensions.

    cd <path>/tkg-extensions-v1.3.0+vmware.1/extensions

    Run all of the commands in these procedures from this location.

  2. Set the context of kubectl to the management cluster or Tanzu Kubernetes cluster on which the extension is deployed.

    kubectl config use-context contour-test-admin@contour-test

IMPORTANT: For all of the extensions, do not delete namespace-role.yaml before the application has been fully deleted. This leads to errors due to the service account that is used by kapp-controller being deleted.

Delete the Contour Extension

  1. Delete the Contour extension.

    kubectl delete -f ingress/contour/contour-extension.yaml
  2. Delete the Contour application.

    kubectl delete app contour -n tanzu-system-ingress
  3. Delete the Contour namespace.

    kubectl delete -f ingress/contour/namespace-role.yaml

Delete the Fluent Bit Extension

  1. Delete the Fluent Bit extension.

    kubectl delete -f logging/fluent-bit/fluent-bit-extension.yaml
  2. Delete the Fluent Bit application.

    kubectl delete app fluent-bit -n tanzu-system-logging
  3. Delete the Fluent Bit namespace.

    kubectl delete -f logging/fluent-bit/namespace-role.yaml

Delete the Prometheus and Grafana Extensions

  1. Delete the Prometheus extension.

    kubectl delete -f monitoring/prometheus/prometheus-extension.yaml
  2. Delete the Prometheus application.

    kubectl delete app prometheus -n tanzu-system-monitoring
  3. Delete the Prometheus namespace.

    kubectl delete -f monitoring/prometheus/namespace-role.yaml
  4. Delete the Grafana extension.

    kubectl delete -f monitoring/grafana/grafana-extension.yaml
  5. Delete the Grafana application.
    kubectl delete app grafana -n tanzu-system-monitoring
  6. Delete the Grafana namespace.

    kubectl delete -f monitoring/grafana/namespace-role.yaml

Delete the External DNS Extension

  1. Delete the External DNS extension.

    kubectl delete -f registry/dns/external-dns-extension.yaml
  2. Delete the External DNS application.
    kubectl delete app external-dns -n tanzu-system-registry
  3. Delete the External DNS namespace.

    kubectl delete -f dns/external-dns/namespace-role.yaml

Delete the Harbor Extension

  1. Delete the Harbor extension.

    kubectl delete -f registry/harbor/harbor-extension.yaml
  2. Delete the Harbor application.
    kubectl delete app harbor -n tanzu-system-registry
  3. Delete the Harbor namespace.

    kubectl delete -f registry/harbor/namespace-role.yaml

Delete the Extensions Utilities

If you delete all extensions from a cluster, you can remove common extensions utilities.

If the extensions are deployed on a Tanzu Kubernetes cluster, optionally delete the cert-manager.

kubectl delete -f ../cert-manager/

Do not delete cert-manager from management clusters.

check-circle-line exclamation-circle-line close-line
Scroll to top icon