make loglevel configurable via environment variable LDAP_LOGLEVEL (#91)
* use LDAP_LOGLEVEL in /opt/bitnami/scripts/openldap/run.sh command Signed-off-by: Johannes Kastl <kastl@b1-systems.de> * README.md: add variable LOGLEVEL Signed-off-by: Johannes Kastl <kastl@b1-systems.de> * set default value 256 for environment variable LDAP_LOGLEVEL Signed-off-by: Johannes Kastl <kastl@b1-systems.de>
This commit is contained in:
parent
db28892357
commit
47e22c9714
|
|
@ -65,6 +65,7 @@ export LDAP_GROUP="${LDAP_GROUP:-readers}"
|
|||
export LDAP_ENABLE_TLS="${LDAP_ENABLE_TLS:-no}"
|
||||
export LDAP_ULIMIT_NOFILES="${LDAP_ULIMIT_NOFILES:-1024}"
|
||||
export LDAP_ALLOW_ANON_BINDING="${LDAP_ALLOW_ANON_BINDING:-yes}"
|
||||
export LDAP_LOGLEVEL="${LDAP_LOGLEVEL:-256}"
|
||||
EOF
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ flags=("-h" "ldap://:${LDAP_PORT_NUMBER}/ ldapi:///")
|
|||
is_boolean_yes "$LDAP_ENABLE_TLS" && flags=("-h" "ldap://:${LDAP_PORT_NUMBER}/ ldaps://:${LDAP_LDAPS_PORT_NUMBER}/ ldapi:///")
|
||||
|
||||
# Add "@" so users can add extra command line flags
|
||||
flags+=("-F" "${LDAP_CONF_DIR}/slapd.d" "-d" "256" "$@")
|
||||
flags+=("-F" "${LDAP_CONF_DIR}/slapd.d" "-d" "$LDAP_LOGLEVEL" "$@")
|
||||
|
||||
info "** Starting slapd **"
|
||||
am_i_root && flags=("-u" "$LDAP_DAEMON_USER" "${flags[@]}")
|
||||
|
|
|
|||
|
|
@ -65,6 +65,7 @@ export LDAP_GROUP="${LDAP_GROUP:-readers}"
|
|||
export LDAP_ENABLE_TLS="${LDAP_ENABLE_TLS:-no}"
|
||||
export LDAP_ULIMIT_NOFILES="${LDAP_ULIMIT_NOFILES:-1024}"
|
||||
export LDAP_ALLOW_ANON_BINDING="${LDAP_ALLOW_ANON_BINDING:-yes}"
|
||||
export LDAP_LOGLEVEL="${LDAP_LOGLEVEL:-256}"
|
||||
EOF
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ flags=("-h" "ldap://:${LDAP_PORT_NUMBER}/ ldapi:///")
|
|||
is_boolean_yes "$LDAP_ENABLE_TLS" && flags=("-h" "ldap://:${LDAP_PORT_NUMBER}/ ldaps://:${LDAP_LDAPS_PORT_NUMBER}/ ldapi:///")
|
||||
|
||||
# Add "@" so users can add extra command line flags
|
||||
flags+=("-F" "${LDAP_CONF_DIR}/slapd.d" "-d" "256" "$@")
|
||||
flags+=("-F" "${LDAP_CONF_DIR}/slapd.d" "-d" "$LDAP_LOGLEVEL" "$@")
|
||||
|
||||
info "** Starting slapd **"
|
||||
am_i_root && flags=("-u" "$LDAP_DAEMON_USER" "${flags[@]}")
|
||||
|
|
|
|||
|
|
@ -191,6 +191,7 @@ The Bitnami Docker OpenLDAP can be easily setup with the following environment v
|
|||
- `LDAP_CUSTOM_SCHEMA_FILE`: Location of a custom internal schema file that could not be added as custom ldif file (i.e. containing some `structuralObjectClass`). Default is **/schema/custom.ldif**"
|
||||
- `LDAP_ULIMIT_NOFILES`: Maximum number of open file descriptors. Default: **1024**.
|
||||
- `LDAP_ALLOW_ANON_BINDING`: Allow anonymous bindings to the LDAP server. Default: **yes**.
|
||||
- `LDAP_LOGLEVEL`: Set the loglevel for the OpenLDAP server (see https://www.openldap.org/doc/admin25/slapdconfig.html for possible values). Default: **256**.
|
||||
|
||||
You can bootstrap the contents of your database by putting LDIF files in the directory `/ldifs` (or the one you define in `LDAP_CUSTOM_LDIF_DIR`). Those may only contain content underneath your base DN (set by `LDAP_ROOT`). You can **not** set configuration for e.g. `cn=config` in those files.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue