aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJake Hunsaker <jhunsake@redhat.com>2022-06-07 13:28:09 -0400
committerJake Hunsaker <jhunsake@redhat.com>2022-06-15 16:01:32 -0400
commit531cc64e472583ba579d85ed26401298a41fe22c (patch)
tree6616c9ca38df1722fa26c1b52326b870be3a5c82
parent56b72eff6cd578556dfc09a1a062e5ed18753c11 (diff)
downloadsos-531cc64e472583ba579d85ed26401298a41fe22c.tar.gz
[sosnode] Properly pass `--namespaces` to nodes
The `namespaces` option was presented to `sos collect`, but was not actually being passed to nodes. Fix this, and gate the usage of the option to version 4.3, or the relevant RHEL backport version like we do for `--container-runtime`. Signed-off-by: Jake Hunsaker <jhunsake@redhat.com>
-rw-r--r--sos/collector/sosnode.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/sos/collector/sosnode.py b/sos/collector/sosnode.py
index d9b998b0..f740b5af 100644
--- a/sos/collector/sosnode.py
+++ b/sos/collector/sosnode.py
@@ -634,6 +634,10 @@ class SosNode():
sos_opts.append(
"--container-runtime=%s" % self.opts.container_runtime
)
+ if self.opts.namespaces:
+ sos_opts.append(
+ "--namespaces=%s" % self.opts.namespaces
+ )
self.update_cmd_from_cluster()