Add accesslog, make debug value configurable
This commit is contained in:
parent
1df1e8d5cd
commit
50029a4c28
@ -6,7 +6,7 @@ FROM alpine
|
||||
# Change to http respositories, so they we can cache the install packages
|
||||
RUN if [ -n ${HTTP_PROXY} ] ; then sed -i -e s'/https/http/' /etc/apk/repositories; fi
|
||||
|
||||
RUN apk add --no-cache bash openldap openldap-back-mdb openldap-clients openldap-overlay-syncprov
|
||||
RUN apk add --no-cache bash openldap openldap-back-mdb openldap-clients openldap-overlay-syncprov openldap-overlay-accesslog
|
||||
|
||||
ADD acl*.ldif samba.ldif wurley.ldif /etc/openldap/schema/
|
||||
ADD certinfo.ldif syncprov*ldif /etc/openldap/
|
||||
|
3
init
3
init
@ -3,6 +3,7 @@ set -e
|
||||
|
||||
NAME="OPENLDAP"
|
||||
SLAPD_CONFIG=${SLAPD_CONFIG:-"/etc/openldap/slapd.d/cn=config"}
|
||||
SLAPD_DEBUG=${SLAPD_DEBUG:-0}
|
||||
|
||||
function stop {
|
||||
echo "Stopping ${NAME}"
|
||||
@ -21,7 +22,7 @@ trap 'stop' SIGTERM
|
||||
|
||||
if [ -z "$@" ]; then
|
||||
SLAPD_URLS="ldapi:/// ldap:/// ldaps:///"
|
||||
SLAPD_OPTIONS="-d 256"
|
||||
SLAPD_OPTIONS="-d ${SLAPD_DEBUG}"
|
||||
|
||||
# If /etc/openldap is an external mount point
|
||||
if mp ${SLAPD_CONFIG}; then
|
||||
|
@ -2,3 +2,4 @@ dn: cn=module{0},cn=config
|
||||
changetype: modify
|
||||
add: olcModuleLoad
|
||||
olcModuleLoad: syncprov.so
|
||||
olcModuleLoad: accesslog.so
|
||||
|
Loading…
Reference in New Issue
Block a user