Skip to content

Commit b50bd72

Browse files
author
David Coutadeur
committed
fix previous commit (cn=monitor acls + rootdn/pw)
1 parent abd0da0 commit b50bd72

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

config-template.ldif

+3-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ dn: cn=config
22
objectClass: olcGlobal
33
cn: config
44
olcConfigFile: /usr/local/openldap/etc/openldap/slapd.conf
5-
olcConfigDir: /tmp/slapd.d-tmp
5+
olcConfigDir: /usr/local/openldap/etc/openldap/slapd.d
66
olcArgsFile: /usr/local/openldap/var/run/slapd.args
77
olcAttributeOptions: lang-
88
olcAuthzPolicy: none
@@ -324,7 +324,8 @@ olcLastMod: TRUE
324324
olcLastBind: TRUE
325325
olcMaxDerefDepth: 15
326326
olcReadOnly: FALSE
327-
olcRootDN: cn=monitor
327+
olcRootDN: CONFIG_MONITORROOTDN
328+
olcRootPW: CONFIG_MONITORROOTPW
328329
olcSyncUseSubentry: FALSE
329330
olcMonitoring: FALSE
330331

slapd-cli

+3
Original file line numberDiff line numberDiff line change
@@ -1637,6 +1637,9 @@ build_config_template() {
16371637
if [ ! -z ${CONFIG_CONFIGROOTDN+x} ] && [ "${CONFIG_CONFIGROOTDN}" != "" ]; then
16381638
sed -i -e "s/^olcRootDN: ${CONFIG_CONFIGROOTDN}$/olcRootDN: CONFIG_CONFIGROOTDN\nolcRootPW: CONFIG_CONFIGROOTPW/" "$2"
16391639
fi
1640+
if [ ! -z ${CONFIG_MONITORROOTDN+x} ] && [ "${CONFIG_MONITORROOTDN}" != "" ]; then
1641+
sed -i -e "s/^olcRootDN: ${CONFIG_MONITORROOTDN}$/olcRootDN: CONFIG_MONITORROOTDN\nolcRootPW: CONFIG_MONITORROOTPW/" "$2"
1642+
fi
16401643

16411644
# replace olcDbDirectory by the given placeholder
16421645
if [ ! -z ${CONFIG_DATADIR+x} ] && [ "${CONFIG_DATADIR}" != "" ]; then

0 commit comments

Comments
 (0)