diff --git a/authentik/outposts/controllers/k8s/base.py b/authentik/outposts/controllers/k8s/base.py index ab7caac34..55c9fe7ad 100644 --- a/authentik/outposts/controllers/k8s/base.py +++ b/authentik/outposts/controllers/k8s/base.py @@ -90,6 +90,12 @@ class KubernetesObjectReconciler(Generic[T]): def down(self): """Delete object if found""" + # Call self.get_reference_object to check if we even need to do anything + try: + self.get_reference_object() + except Disabled: + self.logger.debug("Object not required") + return try: current = self.retrieve() self.delete(current)