summaryrefslogtreecommitdiff
path: root/rhnop-server/debian/postrm
diff options
context:
space:
mode:
authorChristian Pointner <equinox@helsinki.at>2011-03-30 03:01:15 (GMT)
committerChristian Pointner <equinox@helsinki.at>2011-03-30 03:01:15 (GMT)
commitb79e5c9fa899514501df13868717641987750fac (patch)
treed078983f84875355ff2fc3d8cf823bed1253b582 /rhnop-server/debian/postrm
parentb96ad327d3728f79470586416ad72869c0b76900 (diff)
added postinst and postrm (user handling)
Diffstat (limited to 'rhnop-server/debian/postrm')
-rwxr-xr-xrhnop-server/debian/postrm13
1 files changed, 13 insertions, 0 deletions
diff --git a/rhnop-server/debian/postrm b/rhnop-server/debian/postrm
new file mode 100755
index 0000000..18cb882
--- /dev/null
+++ b/rhnop-server/debian/postrm
@@ -0,0 +1,13 @@
+#!/bin/sh
+# postrm script for rhnop-server
+
+set -e
+
+if [ "$1" = "purge" ] ; then
+ if [ -x "$(command -v deluser)" -a -x "$(command -v delgroup)" ]; then
+ deluser --quiet --system rhnop || true
+ delgroup --quiet --system rhnop || true
+ else
+ echo "Not removing rhnop user and group: adduser package not found." >&2
+ fi
+fi