From e96b71026f10d86e245ccf32840f875e0096ca96 Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Sun, 22 Jan 2012 16:15:58 +0000 Subject: automatically fill the ldap on test vm ( denoted by the environment variable set to test ) --- modules/openldap/templates/init_ldap.sh | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 modules/openldap/templates/init_ldap.sh (limited to 'modules/openldap/templates/init_ldap.sh') diff --git a/modules/openldap/templates/init_ldap.sh b/modules/openldap/templates/init_ldap.sh new file mode 100644 index 00000000..8f703fb0 --- /dev/null +++ b/modules/openldap/templates/init_ldap.sh @@ -0,0 +1,25 @@ +#!/bin/bash + +ldapadd -Y EXTERNAL -H ldapi:/// < +dc: <%= dc_suffix.split(',')[0].split('=')[1] %> +objectClass: domain +objectClass: domainRelatedObject +associatedDomain: <%= domain %> + +dn: ou=People,<%= dc_suffix %> +ou: People +objectClass: organizationalUnit + +dn: ou=Group,<%= dc_suffix %> +ou: Group +objectClass: organizationalUnit + +dn: cn=mga-packagers,ou=Group,<%= dc_suffix %> +objectClass: groupOfNames +objectClass: posixGroup +cn: mga-packagers +gidNumber: 5003 +member: cn=manager,<%= dc_suffix %> + +EOF -- cgit v1.2.1