Skip to main content

Uninstall DTC

This topic describes the process for properly uninstalling the Dynamic Traffic Controller (DTC) without leaving behind any resources.

caution

Be aware that once uninstalled, the external-dns.alpha.kubernetes.io/weight annotations on your services will no longer be updated. The most recent value will remain in the annotation (and your DNS provider) until the annotation is manually updated.

Remove Labels

note

This task is optional but recommended.

For each service you have configured with the Dynamic Traffic Controller, you should remove the avesha.dns.metrics.io/monitor: "true" label. This will stop the Dynamic Traffic Controller from observing or updating the service. If you are removing ExternalDNS as well, you can remove the ExternalDNS annotations at this time.

For example:

kubectl edit service frontend

Uninstall the Dynamic Traffic Controller

If you still have the Dynamic Traffic Controller YAML file, you can use the kubectl tool to remove it from the cluster with the following command:

kubectl delete -f gcp-dynamic-traffic-controller.yaml

If you do not have the YAML file, you can use the following commands to remove the Dynamic Traffic Controller:

kubectl delete deployment dns-controller -n external-dns;
kubectl delete serviceaccount dns-controller-sa -n external-dns;
kubectl delete clusterrole dns-controller-clusterrole;
kubectl delete clusterrolebinding dns-controller-clusterrolebinding;