summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2012-07-11 11:26:51 (GMT)
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2012-07-11 11:26:51 (GMT)
commit69bd973cf52c04c3a0c89a6355190e235c417214 (patch)
tree976fa4ac1c73dc59a032397c307adf08742f5b69
parent0d91d43d85653d27e5c33968e5ff132bde644864 (diff)
downloadpykolab-69bd973cf52c04c3a0c89a6355190e235c417214.tar.gz
Add ou=Shared Folders to LDAP setup
-rw-r--r--pykolab/setup/setup_ldap.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/pykolab/setup/setup_ldap.py b/pykolab/setup/setup_ldap.py
index 1ba1dec..43ed653 100644
--- a/pykolab/setup/setup_ldap.py
+++ b/pykolab/setup/setup_ldap.py
@@ -367,6 +367,19 @@ ServerAdminPwd = %(admin_pass)s
# Do the actual synchronous add-operation to the ldapserver
auth._auth.ldap.add_s(dn, ldif)
+ dn = 'ou=Shared Folders,%s' % (_input['rootdn'])
+
+ # A dict to help build the "body" of the object
+ attrs = {}
+ attrs['objectclass'] = ['top','organizationalunit']
+ attrs['ou'] = "Shared Folders"
+
+ # Convert our dict to nice syntax for the add-function using modlist-module
+ ldif = ldap.modlist.addModlist(attrs)
+
+ # Do the actual synchronous add-operation to the ldapserver
+ auth._auth.ldap.add_s(dn, ldif)
+
log.info(_("Writing out cn=kolab,cn=config"))
dn = 'cn=kolab,cn=config'