aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVarsha Teratipally <teratipally@google.com>2022-08-26 14:28:30 +0000
committerJake Hunsaker <jhunsake@redhat.com>2022-08-31 10:09:31 -0400
commit3fbc63e2a9f28c1e5554651b5c7b9d2a4c5c61a8 (patch)
tree1331b620087a6f6e4134c524a1e6b8b1d9ba7301
parent647d52da2ca617b24a044c1733b1217a612da3ad (diff)
downloadsos-3fbc63e2a9f28c1e5554651b5c7b9d2a4c5c61a8.tar.gz
add crio plugin support for Cos
Signed-off-by: Varsha Teratipally <teratipally@google.com>
-rw-r--r--sos/report/plugins/containerd.py29
-rw-r--r--sos/report/plugins/crio.py4
-rw-r--r--sos/report/plugins/docker.py1
3 files changed, 31 insertions, 3 deletions
diff --git a/sos/report/plugins/containerd.py b/sos/report/plugins/containerd.py
new file mode 100644
index 00000000..1977fe22
--- /dev/null
+++ b/sos/report/plugins/containerd.py
@@ -0,0 +1,29 @@
+# This file is part of the sos project: https://github.com/sosreport/sos
+#
+# This copyrighted material is made available to anyone wishing to use,
+# modify, copy, or redistribute it subject to the terms and conditions of
+# version 2 of the GNU General Public License.
+#
+# See the LICENSE file in the source distribution for further information.
+
+from sos.report.plugins import (Plugin, RedHatPlugin, UbuntuPlugin, CosPlugin)
+
+
+class Containerd(Plugin, RedHatPlugin, UbuntuPlugin, CosPlugin):
+
+ short_desc = 'Containerd containers'
+ plugin_name = 'containerd'
+ profiles = ('container',)
+ packages = ('containerd',)
+
+ def setup(self):
+ self.add_copy_spec([
+ "/etc/containerd/",
+ ])
+
+ self.add_cmd_output('containerd config dump')
+
+ # collect the containerd logs.
+ self.add_journal(units='containerd')
+
+# vim: set et ts=4 sw=4 :
diff --git a/sos/report/plugins/crio.py b/sos/report/plugins/crio.py
index 17b016d8..97be87c4 100644
--- a/sos/report/plugins/crio.py
+++ b/sos/report/plugins/crio.py
@@ -9,10 +9,10 @@
# See the LICENSE file in the source distribution for further information.
from sos.report.plugins import (Plugin, RedHatPlugin, UbuntuPlugin,
- SoSPredicate, PluginOpt)
+ SoSPredicate, PluginOpt, CosPlugin)
-class CRIO(Plugin, RedHatPlugin, UbuntuPlugin):
+class CRIO(Plugin, RedHatPlugin, UbuntuPlugin, CosPlugin):
short_desc = 'CRI-O containers'
plugin_name = 'crio'
diff --git a/sos/report/plugins/docker.py b/sos/report/plugins/docker.py
index bb569b3b..879bcd99 100644
--- a/sos/report/plugins/docker.py
+++ b/sos/report/plugins/docker.py
@@ -135,7 +135,6 @@ class UbuntuDocker(Docker, UbuntuPlugin):
def setup(self):
super(UbuntuDocker, self).setup()
self.add_copy_spec([
- "/etc/containerd/",
"/etc/default/docker",
"/run/docker/libcontainerd/containerd/events.log"
])