summaryrefslogtreecommitdiffstats
path: root/debian/apport-hook.py
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--debian/apport-hook.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/debian/apport-hook.py b/debian/apport-hook.py
new file mode 100644
index 00000000..5fb61618
--- /dev/null
+++ b/debian/apport-hook.py
@@ -0,0 +1,11 @@
+import apport.hookutils
+
+def add_info(report):
+ """Add a list of installed packages matching 'virtualbox' or 'linux-headers'"""
+ report['VirtualBox.DpkgList'] = apport.hookutils.command_output(["sh", "-c", "dpkg -l | grep -e virtualbox -e linux-headers"])
+
+ """Add information about installed VirtualBox kernel modules"""
+ report['VirtualBox.ModInfo'] = apport.hookutils.command_output(["sh", "-c",
+ "find /lib/modules/`uname -r` -name \"vbox*\" | xargs -r modinfo"])
+
+ report['LsMod'] = apport.hookutils.command_output(["lsmod"])