We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1a4f065 commit 38e5391Copy full SHA for 38e5391
src/warnet/k8s.py
@@ -17,6 +17,7 @@
17
CADDY_INGRESS_NAME,
18
DEFAULT_NAMESPACE,
19
INGRESS_NAMESPACE,
20
+ KUBE_INTERNAL_NAMESPACES,
21
KUBECONFIG,
22
LOGGING_NAMESPACE,
23
)
@@ -362,7 +363,11 @@ def get_kubeconfig_value(jsonpath):
362
363
def get_namespaces() -> list[V1Namespace]:
364
sclient = get_static_client()
365
try:
- return sclient.list_namespace().items
366
+ return [
367
+ ns
368
+ for ns in sclient.list_namespace().items
369
+ if ns.metadata.name not in KUBE_INTERNAL_NAMESPACES
370
+ ]
371
372
except ApiException as e:
373
if e.status == 403:
0 commit comments