Skip to content

Instantly share code, notes, and snippets.

@sumanthkumarc
Created February 3, 2022 18:10
Show Gist options
  • Save sumanthkumarc/bc513254f36cbe01999558368b7d20ac to your computer and use it in GitHub Desktop.
Save sumanthkumarc/bc513254f36cbe01999558368b7d20ac to your computer and use it in GitHub Desktop.
Namespace conditions
var (
// conditionTypes Namespace condition types that are maintained by namespace_deleter controller.
conditionTypes = []v1.NamespaceConditionType{
v1.NamespaceDeletionDiscoveryFailure,
v1.NamespaceDeletionGVParsingFailure,
v1.NamespaceDeletionContentFailure,
v1.NamespaceContentRemaining,
v1.NamespaceFinalizersRemaining,
}
okMessages = map[v1.NamespaceConditionType]string{
v1.NamespaceDeletionDiscoveryFailure: "All resources successfully discovered",
v1.NamespaceDeletionGVParsingFailure: "All legacy kube types successfully parsed",
v1.NamespaceDeletionContentFailure: "All content successfully deleted, may be waiting on finalization",
v1.NamespaceContentRemaining: "All content successfully removed",
v1.NamespaceFinalizersRemaining: "All content-preserving finalizers finished",
}
okReasons = map[v1.NamespaceConditionType]string{
v1.NamespaceDeletionDiscoveryFailure: "ResourcesDiscovered",
v1.NamespaceDeletionGVParsingFailure: "ParsedGroupVersions",
v1.NamespaceDeletionContentFailure: "ContentDeleted",
v1.NamespaceContentRemaining: "ContentRemoved",
v1.NamespaceFinalizersRemaining: "ContentHasNoFinalizers",
}
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment