Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

run_apacheds.sh: fix ldapmodify calls #11

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions run_apacheds.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ echo "ApacheDS Started"

echo "Starting TLS"

ldapmodify -h 127.0.0.1 -p 10389 -D uid=admin,ou=system -w secret <<EOF
ldapmodify -H ldap://127.0.0.1:10389 -D uid=admin,ou=system -w secret <<EOF
dn: ads-serverId=ldapServer,ou=servers,ads-directoryServiceId=default,ou=config
changeType: modify
replace: ads-keystoreFile
Expand All @@ -64,9 +64,9 @@ ads-certificatePassword: $APACHEDS_TLS_KS_PWD
EOF

echo "Deleting example partition"
ldapdelete -r -h 127.0.0.1 -p 10389 -D uid=admin,ou=system -w secret ads-partitionId=example,ou=partitions,ads-directoryServiceId=default,ou=config
ldapdelete -r -H ldap://127.0.0.1:10389 -D uid=admin,ou=system -w secret ads-partitionId=example,ou=partitions,ads-directoryServiceId=default,ou=config

ldapmodify -h 127.0.0.1 -p 10389 -D uid=admin,ou=system -w secret <<EOF
ldapmodify -H ldap://127.0.0.1:10389 -D uid=admin,ou=system -w secret <<EOF
version: 1

dn: cn=schema
Expand Down Expand Up @@ -127,7 +127,7 @@ $RDN
EOF`


ldapmodify -h 127.0.0.1 -p 10389 -D uid=admin,ou=system -w secret -a <<EOF
ldapmodify -H ldap://127.0.0.1:10389 -D uid=admin,ou=system -w secret -a <<EOF
dn: ads-partitionId=$RDN_VAL,ou=partitions,ads-directoryServiceId=default,ou=config
objectclass: top
objectClass: ads-base
Expand Down Expand Up @@ -293,7 +293,7 @@ echo "ApacheDS Restarted"
if [[ -z "${LDIF_FILE}" ]]; then
echo "No initial LDIF file provided"
else
ldapmodify -h 127.0.0.1 -p 10389 -D uid=admin,ou=system -w secret -f $LDIF_FILE -a -c
ldapmodify -H ldap://127.0.0.1:10389 -D uid=admin,ou=system -w secret -f $LDIF_FILE -a -c
fi


Expand All @@ -302,7 +302,7 @@ fi

echo "Setting admin password"

ldapmodify -h 127.0.0.1 -p 10389 -D uid=admin,ou=system -w secret <<EOF
ldapmodify -H ldap://127.0.0.1:10389 -D uid=admin,ou=system -w secret <<EOF
dn: uid=admin,ou=system
changeType: modify
replace: userPassword
Expand Down