Skip to content
Snippets Groups Projects
Select Git revision
  • c49722fa8298a25c2755fd757d171364d8c69a6b
  • test default protected
  • master protected
  • original
  • pirati-backup protected
  • beta-2
  • beta-1
  • v3.1.4
  • v3.1.3
  • v3.1.2
  • v3.1.1
  • v3.1.0
  • v3.0.16
  • v3.0.15
  • v3.0.14
  • v3.0.13
  • v3.0.12
  • v3.0.11
  • v3.0.10
  • v3.0.9
  • v3.0.8
  • v3.0.7
  • v3.0.6
  • v3.0.5
  • v3.0.4
25 results

views.py

Blame
  • Dockerfile 1.42 KiB
    FROM debian:buster-slim AS builder
    MAINTAINER Andrej Ramašeuski <andrej.ramaseuski@pirati.cz>
    
    ARG BUILD_ENV
    ENV BUILD_ENV=${BUILD_ENV:-"prod"}
    
    ENV PREFIX=/opt
    ENV OPENLDAP_INSTALL_DIR=${PREFIX}/ldap
    ENV OPENLDAP_VERSION=2.4.48
    
    # Temporary install deps
    RUN apt-get update
    RUN apt-get install -y wget build-essential git libtool libdb-dev groff groff-base
    
    # Build tmp OpenLDAP
    RUN mkdir -p ${PREFIX}
    WORKDIR ${PREFIX}
    RUN wget ftp://ftp.openldap.org/pub/OpenLDAP/openldap-release/openldap-${OPENLDAP_VERSION}.tgz
    RUN tar xzf openldap-${OPENLDAP_VERSION}.tgz
    RUN mv openldap-${OPENLDAP_VERSION} ldap
    WORKDIR ${OPENLDAP_INSTALL_DIR}
    RUN ./configure --prefix=${PREFIX} --enable-modules
    RUN make depend
    RUN make
    RUN make install
    
    # Build bcrypt OpenLDAP
    RUN mkdir -p ${OPENLDAP_INSTALL_DIR}/contrib/slapd-modules/passwd
    WORKDIR ${OPENLDAP_INSTALL_DIR}/contrib/slapd-modules/passwd
    RUN git clone https://github.com/wclarie/openldap-bcrypt.git bcrypt
    WORKDIR ${OPENLDAP_INSTALL_DIR}/contrib/slapd-modules/passwd/bcrypt
    RUN make
    RUN make install
    
    FROM osixia/openldap-backup:1.4.0
    MAINTAINER Andrej Ramašeuski <andrej.ramaseuski@pirati.cz>
    
    # Osixia/OpenLDAP extension
    COPY --from=builder /usr/local/libexec/openldap/pw-bcrypt.so /usr/lib/ldap/pw-bcrypt.so
    ADD bootstrap /container/service/slapd/assets/config/bootstrap
    ADD environment /container/environment/01-custom
    RUN mkdir /var/log/slapd && \
        chown openldap.openldap /var/log/slapd
    
    WORKDIR /