summaryrefslogtreecommitdiff
path: root/community-testing/vhba-module/vhba-module.install
diff options
context:
space:
mode:
Diffstat (limited to 'community-testing/vhba-module/vhba-module.install')
-rw-r--r--community-testing/vhba-module/vhba-module.install22
1 files changed, 22 insertions, 0 deletions
diff --git a/community-testing/vhba-module/vhba-module.install b/community-testing/vhba-module/vhba-module.install
new file mode 100644
index 000000000..73029498f
--- /dev/null
+++ b/community-testing/vhba-module/vhba-module.install
@@ -0,0 +1,22 @@
+post_upgrade() {
+ ! grep -q 'cdemu' /etc/group && groupadd cdemu
+ echo " > Updating module dependencies..."
+ EXTRAMODULES='extramodules-3.2-ARCH'
+ depmod $(cat /lib/modules/$EXTRAMODULES/version)
+}
+
+
+post_install() {
+ echo " > Adding 'cdemu' group"
+ ! grep -q 'cdemu' /etc/group && groupadd cdemu
+ echo " > Add 'vhba' to your modules array to autoload it"
+ post_upgrade
+}
+
+post_remove() {
+ post_upgrade
+ echo "Removing 'cdemu' group"
+ groupdel cdemu
+}
+
+# vim:set ts=2 sw=2 et: