summaryrefslogtreecommitdiff
path: root/community-testing/vhba-module/vhba-module.install
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-05-25 00:02:35 +0000
committerroot <root@rshg054.dnsready.net>2012-05-25 00:02:35 +0000
commitaa30737839de3c2a4a1287442cb9859414fb4b0a (patch)
treefe7dabc8a40d713b7b0a781023fe64e03e728bb5 /community-testing/vhba-module/vhba-module.install
parent6553825d7281900890db91a21ac601d7aee9c55e (diff)
Fri May 25 00:02:35 UTC 2012
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: