summaryrefslogtreecommitdiff
path: root/populate-ldap/10a-add-vlv-searches.sh
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2015-01-21 13:02:51 (GMT)
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2015-01-21 13:02:51 (GMT)
commit58ceea9cf45c12ff18df4d45a2590cb60cd21e26 (patch)
tree4a079cbf1ed30585f5636fa29d8794a2534f72aa /populate-ldap/10a-add-vlv-searches.sh
parent51138d19568e5a6305294ddc43d2c70d493a5158 (diff)
downloadkolab-scripts-58ceea9cf45c12ff18df4d45a2590cb60cd21e26.tar.gz
Add a domain base dn VLV index and search
Diffstat (limited to 'populate-ldap/10a-add-vlv-searches.sh')
-rwxr-xr-xpopulate-ldap/10a-add-vlv-searches.sh13
1 files changed, 13 insertions, 0 deletions
diff --git a/populate-ldap/10a-add-vlv-searches.sh b/populate-ldap/10a-add-vlv-searches.sh
index 28614c3..f802c08 100755
--- a/populate-ldap/10a-add-vlv-searches.sh
+++ b/populate-ldap/10a-add-vlv-searches.sh
@@ -38,3 +38,16 @@
echo ""
) | ldapadd -x -h ${ldap_host} -D "${ldap_binddn}" -w "${ldap_bindpw}" -c
+if [ "${domain_base_dn}" != "cn=kolab,cn=config" ]; then
+ (
+ echo "dn: cn=DVS,cn=${domain_db},cn=ldbm database,cn=plugins,cn=config"
+ echo "objectClass: top"
+ echo "objectClass: vlvSearch"
+ echo "cn: DVS"
+ echo "vlvBase: ${domain_base_dn}"
+ echo "vlvScope: 2"
+ echo "vlvFilter: (&(objectclass=domainrelatedobject)(!(objectclass=nstombstone)))"
+ echo "aci: (targetattr = \"*\") (version 3.0;acl \"Read Access\";allow (read,compare,search)(userdn = \"ldap:///anyone\");)"
+ echo ""
+ ) | ldapadd -x -h ${ldap_host} -D "${ldap_binddn}" -w "${ldap_bindpw}" -c
+fi