diff options
author | James Meyer <james.meyer@operamail.com> | 2012-08-07 17:48:21 (GMT) |
---|---|---|
committer | James Meyer <james.meyer@operamail.com> | 2012-08-07 17:48:21 (GMT) |
commit | df0abbd835cdc168cba9da94c72121f39232ce8a (patch) | |
tree | 63e49dd5d0744262da8caa1bd9139202e413902d /abs/core/openldap/openldap.install | |
parent | 9a94627cd98a34f36f7dc200768841a81039afda (diff) | |
download | linhes_pkgbuild-df0abbd835cdc168cba9da94c72121f39232ce8a.zip linhes_pkgbuild-df0abbd835cdc168cba9da94c72121f39232ce8a.tar.gz linhes_pkgbuild-df0abbd835cdc168cba9da94c72121f39232ce8a.tar.bz2 |
openldap 2.4.31
-new
Diffstat (limited to 'abs/core/openldap/openldap.install')
-rw-r--r-- | abs/core/openldap/openldap.install | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/abs/core/openldap/openldap.install b/abs/core/openldap/openldap.install new file mode 100644 index 0000000..cf3cb9f --- /dev/null +++ b/abs/core/openldap/openldap.install @@ -0,0 +1,20 @@ +post_install(){ + groupadd -g 439 ldap &>/dev/null + useradd -u 439 -g ldap -d /var/lib/openldap -s /bin/false ldap &>/dev/null + chown -R ldap:ldap var/lib/openldap &>/dev/null +} + +post_upgrade(){ + getent group ldap >/dev/null 2>&1 || groupadd -g 439 ldap &>/dev/null + getent passwd ldap >/dev/null 2>&1 || useradd -u 439 -g ldap -d /var/lib/openldap -s /bin/false ldap &>/dev/null + chown -R ldap:ldap var/lib/openldap &>/dev/null +} + +post_remove(){ + if getent passwd ldap >/dev/null 2>&1; then + userdel ldap + fi + if getent group ldap >/dev/null 2>&1; then + groupdel ldap + fi +} |