cluster: include maintenance workloads
This commit is contained in:
parent
eb6a27e1bb
commit
bf4e73cce7
@ -36,6 +36,9 @@ _SYSTEM_NAMESPACES = {
|
||||
"postgres",
|
||||
"vault",
|
||||
}
|
||||
_WORKLOAD_ALLOWED_NAMESPACES = {
|
||||
"maintenance",
|
||||
}
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
@ -279,7 +282,11 @@ def _summarize_kustomizations(payload: dict[str, Any]) -> dict[str, Any]:
|
||||
|
||||
|
||||
def _namespace_allowed(namespace: str) -> bool:
|
||||
return bool(namespace) and namespace not in _SYSTEM_NAMESPACES
|
||||
if not namespace:
|
||||
return False
|
||||
if namespace in _WORKLOAD_ALLOWED_NAMESPACES:
|
||||
return True
|
||||
return namespace not in _SYSTEM_NAMESPACES
|
||||
|
||||
|
||||
def _workload_from_labels(labels: dict[str, Any]) -> tuple[str, str]:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user