diff options
Diffstat (limited to 'scripts/common/10-vars')
-rw-r--r-- | scripts/common/10-vars | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/scripts/common/10-vars b/scripts/common/10-vars new file mode 100644 index 0000000..3cfbd8f --- /dev/null +++ b/scripts/common/10-vars @@ -0,0 +1,31 @@ +#!/bin/sh + +if [ "${idm_bootstrap:-}" = true ]; then + resolvers=$bootstrap_resolvers + pkg_host=$pkg_host_ip +else + : ${resolvers:="$(echo "$idm_server_list" | awk '{print $3}')"} +fi + +idm_hostnames=$(echo "$idm_server_list" | awk '{print $1}') + +realm=$(echo "$domain" | tr '[:lower:]' '[:upper:]') + +basedn=$(echo "$domain" | sed -e 's/^/dc=/' -e 's/\./,dc=/g') +ldap_uri=$(printf "ldap://%s.${domain}/ " $idm_hostnames) +ldaps_uri=$(printf "ldaps://%s.${domain}/ " $idm_hostnames) +ldap_hosts=$(printf "%s.${domain} " $idm_hostnames) +accounts_basedn="ou=accounts,${basedn}" +people_basedn="ou=people,${accounts_basedn}" +robots_basedn="ou=robots,${accounts_basedn}" +hosts_basedn="ou=hosts,${accounts_basedn}" +services_basedn="ou=services,${accounts_basedn}" +groups_basedn="ou=groups,${accounts_basedn}" +private_groups_basedn="ou=userprivate,${groups_basedn}" +roles_basedn="ou=roles,${groups_basedn}" +automount_basedn="ou=automount,${basedn}" +sudo_basedn="ou=sudo,${basedn}" +dns_basedn="ou=dns,${basedn}" +kdc_basedn="ou=dns,${basedn}" +mail_basedn="ou=mail,${basedn}" +mail_domains_basedn="ou=domains,${mail_basedn}" |