diff --git a/7 b/7 new file mode 100644 index 0000000..a7c4be9 --- /dev/null +++ b/7 @@ -0,0 +1,15 @@ +version: '3' +services: + ldap-python-webui: + image: aitzol/ldap-webui:latest + volumes: + - settings.ini:rw +# - ./certs:/container/service/slapd/assets/certs:rw +# - ./schema:/container/service/slapd/assets/config/bootstrap/schema/custom + ports: + - 9090:80 + environment: + LDAP_ADMIN_PASSWORD: "admin" + LDAP_READONLY_PASSWORD: "readonly" + + diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..1be8b2f --- /dev/null +++ b/Dockerfile @@ -0,0 +1,26 @@ +# FROM alpine:3.14 +FROM python:3-alpine +#RUN apk add --no-cache bash build-base uwsgi python3-dev +RUN apk add --no-cache --upgrade bash +RUN mkdir -p /www +WORKDIR /www + +COPY . . + +RUN cp settings.ini.example settings.ini +RUN chmod +x start.sh +RUN set -e; \ + apk add --no-cache --virtual .build-deps \ + gcc \ + libc-dev \ + linux-headers \ + ; \ + pip install -r requirements.txt; \ + apk del .build-deps; + +#ENV LDAP_ADMIN_PASSWORD="admin" +#ENV LDAP_READONLY_PASSWORD="readonly" + +EXPOSE 80 8080 +#CMD ["./start.sh"] +ENTRYPOINT ["./start.sh"] diff --git a/docker-compose.yaml b/docker-compose.yaml new file mode 100644 index 0000000..aa1fff6 --- /dev/null +++ b/docker-compose.yaml @@ -0,0 +1,16 @@ +version: '3' +services: + ldap-python-webui: + image: aitzol/ldap-webui:latest + volumes: + - ./settings.ini settings.ini +# - ./certs:/container/service/slapd/assets/certs:rw +# - ./schema:/container/service/slapd/assets/config/bootstrap/schema/custom + ports: + - 9090:80 + + environment: + LDAP_ADMIN_PASSWORD: "admin" + LDAP_READONLY_PASSWORD: "readonly" + + diff --git a/start.sh b/start.sh new file mode 100644 index 0000000..5620829 --- /dev/null +++ b/start.sh @@ -0,0 +1,2 @@ +#!/bin/bash +uwsgi --http :80 --enable-threads --wsgi-file app.py