summaryrefslogtreecommitdiff
path: root/hosted-kolab/02-replace-roles.sh
diff options
context:
space:
mode:
Diffstat (limited to 'hosted-kolab/02-replace-roles.sh')
-rwxr-xr-xhosted-kolab/02-replace-roles.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/hosted-kolab/02-replace-roles.sh b/hosted-kolab/02-replace-roles.sh
new file mode 100755
index 0000000..3e2d260
--- /dev/null
+++ b/hosted-kolab/02-replace-roles.sh
@@ -0,0 +1,18 @@
+#!/bin/bash
+
+ . ./settings.sh
+
+(
+ echo "cn=kolab-admin,${rootdn}"
+) | ldapdelete -x -h ${ldap_host} -D "${ldap_binddn}" -w "${ldap_bindpw}"
+
+(
+ echo "dn: cn=admin-user,${rootdn}"
+ echo "objectclass: top"
+ echo "objectclass: ldapsubentry"
+ echo "objectclass: nsroledefinition"
+ echo "objectclass: nssimpleroledefinition"
+ echo "objectclass: nsmanagedroledefinition"
+ echo "cn: admin-user"
+ echo ""
+) | ldapadd -x -h ${ldap_host} -D "${ldap_binddn}" -w "${ldap_bindpw}"