diff --git a/index.sh b/index.sh index 43fc5b0..91057a8 100644 --- a/index.sh +++ b/index.sh @@ -5,6 +5,7 @@ set -e org_name="Theta42" domain="theta42.com" password=$1 +ldap_base="dc=theta42,dc=com" echo "slapd slapd/internal/adminpw string $password" | debconf-set-selections echo "slapd slapd/password1 string $password" | debconf-set-selections @@ -23,7 +24,7 @@ echo "slapd slapd/invalid_config boolean true" | debconf-set-selections apt install -y slapd ldap-utils echo '' > /etc/ldap/ldap.conf -echo 'BASE dc=theta42,dc=com' >> /etc/ldap/ldap.conf +echo 'BASE $ldap_base' >> /etc/ldap/ldap.conf echo 'URI ldap://localhost' >> /etc/ldap/ldap.conf ldapadd -Y EXTERNAL -H ldapi:/// -f files/sshkey.ldif