'partitions-only',
'ldap-base',
'ldap-backend=s',
- 'ldap-module=s',
+ 'ldap-backend-type=s',
'aci=s');
if (options == undefined) {
--partitions-only Configure Samba's partitions, but do not modify them (ie, join a BDC)
--ldap-base output only an LDIF file, suitable for creating an LDAP baseDN
--ldap-backend LDAPSERVER LDAP server to use for this provision
- --ldap-module MODULE LDB mapping module to use for the LDAP backend
+ --ldap-backend-type TYPE OpenLDAP or Fedora DS
--aci ACI An arbitary LDIF fragment, particularly useful to loading a backend ACI value into a target LDAP server
You must provide at least a realm and domain
}
var blank = (options["blank"] != undefined);
-var ldapbase = (options["ldap-base"] != undefined);
var ldapbackend = (options["ldap-backend"] != undefined);
-var ldapmodule = (options["ldap-module"] != undefined);
+var ldapbackendtype = options["ldap-backend-type"];
var partitions_only = (options["partitions-only"] != undefined);
var paths = provision_default_paths(subobj);
if (options["aci"] != undefined) {
if (options["ldap-backend"] == "ldapi") {
subobj.LDAPBACKEND = subobj.LDAPI_URI;
}
- if (!ldapmodule) {
- subobj.LDAPMODULE = "entryuuid";
+ if (ldapbackendtype == undefined) {
+
+ } else if (ldapbackendtype == "openldap") {
+ subobj.LDAPMODULE = "normalise,entryuuid";
subobj.TDB_MODULES_LIST = "";
+ } else if (ldapbackendtype == "fedora-ds") {
+ subobj.LDAPMODULE = "nsuniqueid";
}
+ subobj.BACKEND_MOD = subobj.LDAPMODULE + ",paged_searches";
subobj.DOMAINDN_LDB = subobj.LDAPBACKEND;
- subobj.DOMAINDN_MOD2 = "," + subobj.LDAPMODULE + ",paged_searches";
subobj.CONFIGDN_LDB = subobj.LDAPBACKEND;
- subobj.CONFIGDN_MOD2 = "," + subobj.LDAPMODULE + ",paged_searches";
subobj.SCHEMADN_LDB = subobj.LDAPBACKEND;
- subobj.SCHEMADN_MOD2 = "," + subobj.LDAPMODULE + ",paged_searches";
message("LDAP module: %s on backend: %s\n", subobj.LDAPMODULE, subobj.LDAPBACKEND);
}
var creds = options.get_credentials();
message("Provisioning for %s in realm %s\n", subobj.DOMAIN, subobj.REALM);
message("Using administrator password: %s\n", subobj.ADMINPASS);
-if (ldapbase) {
- provision_ldapbase(subobj, message, paths);
- message("Please install the LDIF located in " + paths.ldap_basedn_ldif + ", " + paths.ldap_config_basedn_ldif + " and " + paths.ldap_schema_basedn_ldif + " into your LDAP server, and re-run with --ldap-backend=ldap://my.ldap.server\n");
-} else if (partitions_only) {
+if (partitions_only) {
provision_become_dc(subobj, message, false, paths, system_session);
} else {
provision(subobj, message, blank, paths, system_session, creds, ldapbackend);
message("--host-guid='%s' \\\n", subobj.HOSTGUID);
}
message("--policy-guid='%s' --host-name='%s' --host-ip='%s' \\\n", subobj.POLICYGUID, subobj.HOSTNAME, subobj.HOSTIP);
- message("--invocationid='%s' \\\n", subobj.INVOCATIONID);
+ if (subobj.INVOCATIONID != undefined) {
+ message("--invocationid='%s' \\\n", subobj.INVOCATIONID);
+ }
message("--adminpass='%s' --krbtgtpass='%s' \\\n", subobj.ADMINPASS, subobj.KRBTGTPASS);
message("--machinepass='%s' --dnspass='%s' \\\n", subobj.MACHINEPASS, subobj.DNSPASS);
- message("--root='%s' --nobody='%s' --nogroup-'%s' \\\n", subobj.ROOT, subobj.NOBODY, subobj.NOGROUP);
+ message("--root='%s' --nobody='%s' --nogroup='%s' \\\n", subobj.ROOT, subobj.NOBODY, subobj.NOGROUP);
message("--wheel='%s' --users='%s' --server-role='%s' \\\n", subobj.WHEEL, subobj.USERS, subobj.SERVERROLE);
if (ldapbackend) {
message("--ldap-backend='%s' \\\n", subobj.LDAPBACKEND);
}
- if (ldapmodule) {
- message("--ldap-mdoule='%s' \\\n", + subobj.LDAPMODULE);
+ if (ldapbackendtype != undefined) {
+ message("--ldap-backend-type='%s' \\\n", + ldapbackendtype);
}
message("--aci='" + subobj.ACI + "' \\\n")
}